traj_elo | R Documentation |
calculate individual Elo rating trajectory over time
traj_elo(
eloobject,
ID,
from = min(eloobject$stability$date),
to = max(eloobject$stability$date)
)
eloobject |
result from |
ID |
character, the ID(s) of the individual(s) |
from |
character, from which date onwards should the trajectory be calculated. By default the first date in the sequence is used |
to |
character, until which date should the trajectory be calculated. By default the last date in the sequence is used |
A data.frame
with as many lines as specified in ID
, columns for ID, date range, the actual slope (trajectory), and the number of observed interactions within the date range
Christof Neumann
data(adv)
SEQ <- elo.seq(winner = adv$winner, loser = adv$loser, Date = adv$Date)
traj_elo(SEQ, "a")
traj_elo(SEQ, "a", from = "2010-01-20", to = "2010-01-30")
# no slope available if ID was not observed interacting
# inside the date range
traj_elo(SEQ, "a", from = "2010-01-17", to = "2010-01-18")
# no slope available if ID was only observed interacting
# once within the date range
traj_elo(SEQ, "a", from = "2010-01-17", to = "2010-01-19")
# for several individuals
traj_elo(SEQ, c("a", "b", "c"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.