Description Usage Arguments Details Value Note Examples
The function takes a dataframe with either 4 or 5 columns and converts it to an interData object to be used for analysis in functions in this package.
1 |
df |
data frame with 4 columns as described in the details. |
... |
arguments to be passed to the as.POSIXct function for converting time data |
The columns of the data frame being passed to this function should be as follows:
- column 1: a vector with the 1st participant in a dyadic interaction/game
- column 2: a vector with the 2nd participant in a dyadic interaction/game
- column 3: the outcome of the interaction coded as either
> 1 if player 1 was the winner
> -1 if player 2 was the winner
> 0 if the outcome was a tie
- column 4: a vector to be coerced to the class POSIXct by the as.POSIXct function denoting the time of the interaction/game
a list like object of class interData with three elements - element 1: character of players in the interactions - element 2: range of time that the data frame encompasses - element 3: data frame with the players interactions, outcome, and date
Interactions where player.1 is equal to player.2 are automatically removed as no algorithm takes into account what to do when a player plays against themself.
1 2 3 4 5 6 7 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.