Recommendations and Ranking
Predict a reader’s rating
BOTIE
Examples, experiments and workspace controls
Connect a tool's inputs to see what it produces. You can try a branch before connecting it to Result.
Try your own inputs
Use a copy of the example to try your own data. Keep the problem's assumptions in mind, and predict the effect of a change before checking the output. You can also add another branch to compare two ways of doing the calculation.
Context for this challenge
Subtract neighbour means, compute a weighted average of deviations, then add the target reader’s mean.
Readers use rating scales differently. Botie must transfer neighbours' deviations from their usual ratings rather than copying raw scores.
Subtract each neighbour mean, combine deviations with positive similarity weights, divide by total weight, and add the target reader's mean.
Examples and results
- Neighbour ratings
- 05
- 13
- Neighbour means
- 03
- 14
- Positive similarity weights
- 00.75
- 10.25
- Target reader mean
3
- Required result
4.25
- Neighbour ratings
- 04
- Neighbour means
- 03
- Positive similarity weights
- 00.5
- Target reader mean
3
- Required result
4
Try a fresh construction
This clears this draft, including its undo history. Earlier successful attempts stay recorded. Build again without opening hints to record an independent attempt.
Stuck? Inspect a worked construction
The tools below form one possible solution. You can assemble it, follow its signals, and undo that change to return to your own construction.
Assumptions and test precision
Weights must be non-negative with positive total. Missing neighbours are excluded before this calculation. Numerical tests allow a difference of 0.001. Lists and structures must also have the right shape.
A generous reviewer rated below their usual level
This check uses the pieces from “Transfer centred neighbour preferences”.
BOTIE
- Neighbour ratings
- 03
- 14
- Neighbour means
- 04.5
- 13.5
- Positive similarity weights
- 00.6
- 10.4
- Target reader mean
3.2
Use a number, text, or an array matching the requested result. For a matrix, put each row in brackets. Saving your prediction runs your current construction on these inputs and checks the earlier examples too.
Build a construction in the workspace above first. This case will test those pieces.
Why must the divisor use the sum of similarity weights rather than the number of neighbours?
A weighted deviation needs a matching weighted normalisation before it is transferred to another baseline.
Weights must be non-negative with positive total. Missing neighbours are excluded before this calculation.
Work through the Python challenges →