
Temporal rollup for a TPS crime data.frame
Source:R/tps_all_analyze.R
morie_tps_temporal_summary.RdYear / month / day-of-week / hour-of-day rollups, plus a coverage line. Robust to missing columns: only includes tables for the fields actually present.
Examples
# \donttest{
df <- try(morie_datasets_tps_assault(max_features = 200L))
if (!inherits(df, "try-error")) {
res <- try(morie_tps_temporal_summary(df, ds_name = "assault"))
if (!inherits(res, "try-error")) str(res, max.level = 1)
}
#> List of 8
#> $ title : chr "TPS temporal -- assault"
#> $ call : NULL
#> $ summary_lines :List of 4
#> $ tables :List of 4
#> $ warnings : chr(0)
#> $ interpretation: chr "Temporal rollup over 5 incident(s) in the assault dataset."
#> $ payload : list()
#> $ sections : list()
#> - attr(*, "class")= chr [1:3] "morie_tps_result" "morie_rich_result" "list"
# }