Electronic Science and Technology ›› 2020, Vol. 33 ›› Issue (2): 54-59.doi: 10.16180/j.cnki.issn1007-7820.2020.02.010

Previous Articles     Next Articles

Implementation of a Collaborative Filtering Algorithm Based on Improved Similarity

XU Fengxiang   

  1. School of Computer,North China University of Technology,Beijing 100144,China
  • Received:2019-01-03 Online:2020-02-15 Published:2020-03-12
  • Supported by:
    Beijing Municipal Natural Science Foundation-City Education Commission Joint Key Project(KZ201810009011)


When calculating the similarity, the collaborative filtering algorithm assigns similar weights to all users or items, which will lead to deviations in the similarity calculation. Aiming at this problem, an improved similarity algorithm was proposed to fix the error. Firstly, when calculating the similarity between users, the active user influence factor was added by the number of active users, and when calculating the similarity between items. When calculating the similarity between items, the hot item influence factor was added according to the popularity of the item, then similarity was maximum normalized. Finally, the rating of movies was predicted by using similarity matrix. The experimental results showed that the improved similarity algorithm was more accurate in rating prediction, and the average absolute error was stable at around 0.72.

Key words: collaborative filtering, pearson similarity, similarity algorithm, normalization, mean absolute error, rating prediction

CLC Number: 

  • TP301.6