Analyzes move time duration and remaining clock time distribution per game and color.
Arguments
- data
Ply-by-ply move data returned by
lic_tidy_moves()containinggame_id,color, andclock.- threshold_time_trouble
Threshold in seconds below which a move is counted as time trouble. Default is 10.
Value
A tibble::tibble with columns: game_id, color, moves_count, avg_move_time,
max_move_time, min_clock, and time_trouble_moves.
Details
This is an offline data aggregation function (no API network request).
Requires ply-by-ply move data returned by lic_tidy_moves().
Examples
sample_moves <- tibble::tibble(
game_id = rep("g1", 6),
ply = 1:6,
color = c("white", "black", "white", "black", "white", "black"),
clock = c(180, 179, 175, 170, 160, 155)
)
lic_stats_clocks(sample_moves)
#> # A tibble: 2 × 7
#> game_id color moves_count avg_move_time max_move_time min_clock
#> <chr> <chr> <int> <dbl> <dbl> <dbl>
#> 1 g1 black 3 12 15 155
#> 2 g1 white 3 10 15 160
#> # ℹ 1 more variable: time_trouble_moves <int>