Adaptation and Personalization, Vol. 1, Issue 1, Dec  2019, Pages 21-41; DOI: 10.31058/j.adp.2019.11002 10.31058/j.adp.2019.11002

Advanced cosine measures for collaborative filtering

, Vol. 1, Issue 1, Dec  2019, Pages 21-41.

DOI: 10.31058/j.adp.2019.11002

Loc Nguyen 1* , Ali A. Amer 2

1 Loc Nguyen’s Academic Network, Board of Advisors, Long Xuyen, Vietnam

2 TAIZUniversity, Computer Science Department, Taiz, Yemen

Received: 26 July 2019; Accepted: 30 August 2019; Published: 17 October 2019

Full-Text HTML | Download PDF | Views 1078 | Download 647


Cosine similarity is an important measure to compare two vectors for many researches in data mining and information retrieval. In this research, cosine measure and its advanced variants for collaborating filtering (CF) are evaluated. Cosine measure is effective but it has a drawback that there may be two end points of two vectors which are far from each other according to Euclidean distance, but their cosine is high. This is negative effect of Euclidean distance which decreases accuracy of cosine similarity. Therefore, a so-called triangle area (TA) measure is proposed as an improved version of cosine measure. TA measure uses ratio of basic triangle area to whole triangle area as reinforced factor for Euclidean distance so that it can alleviate negative effect of Euclidean distance whereas it keeps simplicity and effectiveness of both cosine measure and Euclidean distance in making similarity of two vectors. TA is considered as an advanced cosine measure. TA and other advanced cosine measures are tested with other similarity measures. From experimental results, TA is not a preeminent measure but it is better than traditional cosine measures in most cases and it is also adequate to real-time application. Moreover, its formula is simple too.


Collaborating Filtering (CF), Cosine, Similarity Measure, Nearest Neighbors (NN) Algorithm, Rating Matrix


© 2017 by the authors. Licensee International Technology and Science Press Limited. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.


[1] R.D.; Torres Júnior. Combining Collaborative and Content-based Filtering to Recommend Research Paper. Universidade Federal do Rio Grande do Sul, Porto Alegre, 2004.

[2] M.P.T.; Do, D.V. Nguyen; L. Nguyen, Model-based Approach for Collaborative Filtering, in Proceedings of The 6th International Conference on Information Technology for Education (IT@EDU2010), Ho Chi Minh, 2010.

[3] B. Sarwar; G. Karypis, J.; Konstan; J. Riedl. Item-based Collaborative Filtering Recommendation Algorithms. In Proceedings of the 10th international conference on World Wide Web, Hong Kong, 2001.

[4] H. Liu; Z. Hu; A. Mian; H. Tian; X. Zhu. A new user similarity model to improve the accuracy of collaborative filtering. Knowledge-Based Systems, 2014, 56, 156-166.

[5] B.K. Patra; R. Launonen; V. Ollikainen; S. Nandi. A new similarity measure using Bhattacharyya coefficient for collaborative filtering in sparse data. Knowledge-Based Systems, 2015, 82, 163-177.

[6] Y.S. Lin, J.Y. Jiang; S.J. Lee. A Similarity Measure for Text Classification and Clustering.IEEE Transactions on Knowledge and Data Engineering, 2013, 26(7),1575-1590.

[7] J.L. Herlocker; J.A. Konstan; L.G. Terveen; J.T. Riedl. Evaluating Collaborative Filtering Recommender Systems.ACM Transactions on Information Systems (TOIS),2004,22(1), 5-53.

[8] GroupLens. MovieLens datasets.GroupLens Research Project, University of Minnesota, USA, 22 April 1998. Available online: on 3 August 2012).

Related Articles