calculate ratings from sequence of rating events, allowing for more than two stimuli

1 |

`xdata` |
data.frame or matrix with stimulus IDs, each row representing one trial, needs to contain at least two columns |

`winner` |
numeric vector of the same length as |

`runs` |
numeric, the number of times the data set should be randomized |

`startvalue` |
numeric, initial value of ratings, by default |

`k` |
numeric, value of |

`progressbar` |
logical, by default |

`mode` |
character, either |

The `mode="avg"`

option considers the losers of the trial as one individual/stimulus, whose rating is averaged. This reflects one rating step for each trial (as for `elochoice()`

).

The `mode="seq"`

option runs a sequence of interactions *within* a trial, i.e. one rating step for each of the loosing stimuli. E.g. if you have three stimuli, that would be two rating steps. With four stimuli, we would have three steps, etc.

Because of the larger number of rating events with `mode="seq"`

, the range of Elo-ratings will be larger as compared to `mode="avg"`

. The average values will be the same for both though (start value). See examples...

Also note that this is an experimental function that has not yet been tested thoroughly! In addition, this function calculates winning probabilities in a slightly different way as compared to `elochoice`

, i.e. based on normal probabilities (see `elochoice`

).

a matrix with ratings

Christof Neumann

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | ```
## Not run:
data(physical)
y <- round(triplets(physical[,2:3], winner=rep(1,nrow(physical)), runs = 1))
x <- ratings(elochoice(physical$Winner, physical$Loser, runs = 1), show = "all", drawplot = FALSE)
x <- x[order(names(x))]
plot(x, y)
xdata <- as.matrix(t(sapply(1:500, function(x)sample(letters[1:8], 3))))
xdata <- t(apply(xdata, 1, sort))
winner <- sample(1:3, nrow(xdata), TRUE, prob = c(4,0.8, 0.1))
x <- triplets(xdata, winner, runs=20, mode="avg")
y <- triplets(xdata, winner, runs=20, mode="seq")
# note different ranges along the axes
plot(colMeans(x), colMeans(y))
range(colMeans(x))
range(colMeans(y))
## End(Not run)
``` |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.