For recommendation system, there are two problems:
how to quantify the user's interest in a certain item based on the numbers you collected
how to use the quantified interest data to recommend new items to the user
I guess you are more interested in the first problem.
To solve the first problem, you need either linear combination or some other fancy functions to combine all the numbers. There is really no a single universal function for all systems. It heavily depends on the type of your users and your items. If you want a high quality recommandation system, you need to have some data to do machine learning to train your functions.
For the second problem, it's somehow the same thing, plus you need to analyze all the items to abstract some relationships between each other. You can google "Netflix prize" for some interesting info.