|
CFEngine API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.recommender.algorithms.Experimental.ContinuousBayesNetAlgorithm
Describes an implementation of the CFAlgorithm interface to make CF predictions using a Bayesian network.
Field Summary | |
(package private) ContinuousBayesNet |
model
|
Constructor Summary | |
ContinuousBayesNetAlgorithm(DataManager mgr)
|
Method Summary | |
long |
getAveragePredictionTime()
Very useful to get the prediction time after a bunch of experiment Should be implemented within each algorithm class. |
ItemRating[] |
getRecommendations(int activeUser,
int n)
Return top n recommendations for the active user. |
ItemRating[] |
getRecommendationsByType(int activeUser,
int n,
int type)
Added by Yun Wang Return top n recommendations for the active user of specific type. |
ItemPrediction |
predictRating(int activeUser,
int item)
predicts the rating for the given user and item. |
java.lang.String |
toString()
Return the name of algorithm. |
void |
updateUser(int userID)
Notify algorithm that the given user's ratings have changed. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
ContinuousBayesNet model
Constructor Detail |
public ContinuousBayesNetAlgorithm(DataManager mgr)
Method Detail |
public ItemRating[] getRecommendations(int activeUser, int n) throws java.sql.SQLException, CFNotImplementedException
CFAlgorithm
getRecommendations
in interface CFAlgorithm
activeUser
- n
-
java.sql.SQLException
CFNotImplementedException
public ItemRating[] getRecommendationsByType(int activeUser, int n, int type) throws java.sql.SQLException, CFNotImplementedException
CFAlgorithm
getRecommendationsByType
in interface CFAlgorithm
activeUser
- n
- type
-
java.sql.SQLException
CFNotImplementedException
public ItemPrediction predictRating(int activeUser, int item) throws CFNotImplementedException
predictRating
in interface CFAlgorithm
activeUser
- item
-
CFNotImplementedException
public void updateUser(int userID) throws CFNotImplementedException
CFAlgorithm
updateUser
in interface CFAlgorithm
userID
-
CFNotImplementedException
public long getAveragePredictionTime() throws CFNotImplementedException
CFAlgorithm
getAveragePredictionTime
in interface CFAlgorithm
CFNotImplementedException
public java.lang.String toString()
CFAlgorithm
toString
in interface CFAlgorithm
toString
in class java.lang.Object
|
CFEngine API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |