Build a synthetic OTIS data.frame for a given publication id.
Source:R/synth_otis.R
morie_synth_otis.RdReturns a data.frame mirroring the column shape + categorical level
set of the published OTIS dataset for the given id (a01,
b01..b09, c01..c12, or d01..d07). Schema is derived from the
Ontario MCSCS XLSX data dictionary that ships at
inst/extdata/otis_dictionary.json. Values are randomly drawn
from the dictionary categorical levels (or 0..80 for count
columns); used only for offline-no-fixture fallback in tests and
demos. NOT a substitute for the real OTIS data published at
https://data.ontario.ca/dataset/data-on-inmates-in-ontario.
See also
morie_synth_otis_all for the full 29-dataset
list; morie_datasets_otis_a01 and friends for the
real bundled+live loaders.
Examples
df <- morie_synth_otis("c11", n = 50)
head(df)
#> EndFiscalYear Aggregate_Duration NumberIndividuals_RestrictiveConfinement
#> 1 2018 6 to 10 days 59
#> 2 2021 21 to 25 days 50
#> 3 2024 16 to 20 days 33
#> 4 2018 21 to 25 days 9
#> 5 2019 11 to 15 days 0
#> 6 2022 16 to 20 days 42
#> NumberIndividuals_Segregation
#> 1 65
#> 2 18
#> 3 16
#> 4 33
#> 5 74
#> 6 30