score_keeper | R Documentation |
This function computes the sum and mean of the player's and computer's values
and calculates the effect size based on the given mode (t
or pt
).
score_keeper(player_values, comp_values, mode)
player_values |
A numeric vector representing the values of the player's cards. |
comp_values |
A numeric vector representing the values of the computer's cards. |
mode |
A character string representing the mode of the game, either 't' for independent t-test or 'pt' for paired t-test. |
A list containing:
player_sum
: Sum of player's values.
player_mean
: Mean of player's values.
comp_sum
: Sum of computer's values.
comp_mean
: Mean of computer's values.
effect_size
: Calculated effect size based on the given mode.
# Calculate scores for a simple game
player_vals <- c(2.5, 3.0, 4.5)
comp_vals <- c(3.5, 2.0, 4.0)
scores <- score_keeper(player_vals, comp_vals, mode = "t")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.