You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@mahout.apache.org by Zia mel <zi...@gmail.com> on 2013/02/04 16:54:34 UTC

Threshold-based neighborhood and getReach

Hi , when selecting Threshold-based neighborhood, as the threshold
increase the precision increase which makes sense. However, the
getReach max provide recommendations for 0.2 users and decrease to
0.0002 , is that normal? The recall also drops. When using a
fixed-size neighborhood getReach provide much higher results.

//=== Code used ====

UserNeighborhood neighborhood =new
ThresholdUserNeighborhood(thresholdValue, similarity, model);
return new GenericUserBasedRecommender(model, neighborhood, similarity);

IRStatistics stats = evaluator.evaluate(recommenderBuilder, null,
model, null, 10, GenericRecommenderIRStatsEvaluator.CHOOSE_THRESHOLD,
1.0);

stats.getReach()
//===

Thanks

Re: Threshold-based neighborhood and getReach

Posted by Sean Owen <sr...@gmail.com>.
You are asking for a smaller and smaller neighborhood around a user.
At some point the neighborhood includes no users, for some people --
or, the neighborhood includes no new items. Nothing can be
recommended, and so recall drops. Precision and recall tend to go in
opposite directions for similar reasons.

On Mon, Feb 4, 2013 at 3:54 PM, Zia mel <zi...@gmail.com> wrote:
> Hi , when selecting Threshold-based neighborhood, as the threshold
> increase the precision increase which makes sense. However, the
> getReach max provide recommendations for 0.2 users and decrease to
> 0.0002 , is that normal? The recall also drops. When using a
> fixed-size neighborhood getReach provide much higher results.
>
> //=== Code used ====
>
> UserNeighborhood neighborhood =new
> ThresholdUserNeighborhood(thresholdValue, similarity, model);
> return new GenericUserBasedRecommender(model, neighborhood, similarity);
>
> IRStatistics stats = evaluator.evaluate(recommenderBuilder, null,
> model, null, 10, GenericRecommenderIRStatsEvaluator.CHOOSE_THRESHOLD,
> 1.0);
>
> stats.getReach()
> //===
>
> Thanks