item-summary-functions: Specific functions for computing item summary

Description Usage Arguments Details Value See Also Examples

Description

This page describes specific functions for computing item summary.

Usage

1
2
3
4
5
6
7
8
9
summary_mean_sd_score(cr_data, prefix = "", ...)

summary_min_max_score(cr_data, prefix = "", ...)

summary_sum_score(cr_data, prefix = "", ...)

summary_num_games(cr_data, prefix = "", ...)

summary_num_players(cr_data, prefix = "", ...)

Arguments

cr_data

Competition results in format ready for to_longcr.

prefix

Possible prefix to add to item summary's names.

...

Additional arguments to be passed to or from methods.

Details

Implementations of summary_fun should be able to take prefix and ... as parameters.

Value

All summary_funs return a named vector of item summaries (names are given before adding prefix). This is a list of currently implemented summary_funs:

summary_mean_sd_score

Returns a vector: meanScore - mean score; sdScore - standard deviation of scores;

summary_min_max_score

Returns a vector: minScore - minimum score; maxScore - maximum score;

summary_sum_score

Returns a vector: sumScore - sum of all present scores;

summary_num_games

Returns a vector: numGames - number of unique games;

summary_num_players

Returns a vector: numPlayers - number of unique players.

See Also

item-summary for description of computing item summary.

item-summary-add for adding item summary to competition results.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
cr_data <- data.frame(
  game = rep(1:20, each = 2),
  player = rep(1:10, times = 4),
  score = 31:70,
  season = rep(1:2, each = 20)
)

# Computing item summary
summary_mean_sd_score(cr_data)
summary_min_max_score(cr_data)
summary_min_max_score(cr_data, prefix = "total_")

echasnovski/comperes documentation built on June 21, 2017, 1:17 a.m.