public final class GroupLensRecommender extends Object implements Recommender
Recommender implemented for the GroupLens demo.| Constructor and Description |
|---|
GroupLensRecommender() |
GroupLensRecommender(DataModel dataModel)
Alternate constructor that takes a
DataModel argument, which allows this Recommender
to be used with the RecommenderEvaluator framework. |
| Modifier and Type | Method and Description |
|---|---|
float |
estimatePreference(long userID,
long itemID) |
DataModel |
getDataModel() |
List<RecommendedItem> |
recommend(long userID,
int howMany) |
List<RecommendedItem> |
recommend(long userID,
int howMany,
IDRescorer rescorer) |
void |
refresh(Collection<Refreshable> alreadyRefreshed) |
void |
removePreference(long userID,
long itemID) |
void |
setPreference(long userID,
long itemID,
float value) |
String |
toString() |
public GroupLensRecommender()
throws IOException,
TasteException
IOExceptionTasteExceptionpublic GroupLensRecommender(DataModel dataModel) throws TasteException
Alternate constructor that takes a DataModel argument, which allows this Recommender
to be used with the RecommenderEvaluator framework.
dataModel - data modelTasteException - if an error occurs while initializing thispublic List<RecommendedItem> recommend(long userID, int howMany) throws TasteException
recommend in interface RecommenderTasteExceptionpublic List<RecommendedItem> recommend(long userID, int howMany, IDRescorer rescorer) throws TasteException
recommend in interface RecommenderTasteExceptionpublic float estimatePreference(long userID,
long itemID)
throws TasteException
estimatePreference in interface RecommenderTasteExceptionpublic void setPreference(long userID,
long itemID,
float value)
throws TasteException
setPreference in interface RecommenderTasteExceptionpublic void removePreference(long userID,
long itemID)
throws TasteException
removePreference in interface RecommenderTasteExceptionpublic DataModel getDataModel()
getDataModel in interface Recommenderpublic void refresh(Collection<Refreshable> alreadyRefreshed)
refresh in interface RefreshableCopyright © 2008–2013 The Apache Software Foundation. All rights reserved.