# Collaborative filtering using a linear model

Consider I have a set of movies and a set of users ($A$,$B$,$C$,$D$) and a matrix with related scores (I can have gaps in this matrix).

Consider a linear regression model where a specific user A's rating is meant to be a weighted average of other users ratings:

$$R_A = a + w_B R_B + w_C R_C+ w_D R_D$$

where $R_A$ is a rating of user A and so on, $w_B$ is the weight parameter for rating $R_B$ and $a$ is a normalization factor.

The following is the table I have got:

Usersm1m2m3m4m5m6m7m8
 A 3 4 5   1 
 B  5 5 5    1
 C  2   5 5 3 4
 D 4 5 4 4    2

Question: How can I derive a parameter estimation method and use it to obtain the four weights $w_B$, $w_C$, $w_D$?

• Cross-posted on CS.SE: cs.stackexchange.com/q/41591/755 See that question for my comments and suggestions on how to improve the question.
– D.W.
Apr 21 '15 at 23:19
• is R_A scalar or a vector corresponding to each movie ? Apr 18 '18 at 10:56