나와 유사한 사람들의 정보를 이용한 영화 추천하기 (UBCF 실습) :: 추천 시스템: 원리와 구현 - mindscale
Skip to content

나와 유사한 사람들의 정보를 이용한 영화 추천하기 (UBCF 실습)

User-Based Collaborative Filtering(UBCF)에서 조정할 수 있는 파라미터 알아보기

recommenderRegistry$get_entries(method = 'UBCF')

피어슨 상관계수를 이용하여 추천해보기

rec <- Recommender(m, method = 'UBCF', param = list(method = 'pearson'))

who <- 1
as(predict(rec, m[who, ], type = 'ratings'), 'list')
as(predict(rec, m[who, ], type = 'topNList', n = 5), 'list')

코사인 유사도를 이용하여 추천해보기

rec <- Recommender(m, method = 'UBCF', param = list(method = 'cosine'))
as(predict(rec, m[who, ], type = 'topNList', n = 5), 'list')

추천 시 특정 사용자와 인접한 이웃의 수를 50으로 설정하여 추천해보기

rec <- Recommender(m, method = 'UBCF', param = list(method = 'cosine', nn = 50))
as(predict(rec, m[who, ], type = 'topNList', n = 5), 'list')