fix_granularity.Rd
Sets a given granularity to a set of data by aggregating or imputing them.
fix_granularity(
tag_wanted,
period_start,
period_end,
temporal_granularity,
stat_unit_wanted = NULL,
aggregation_method = mean_aggregate,
impute_method = linear_impute,
information_lost_after = 5 * temporal_granularity
)
A string containing the tag of the wanted data.
A date marking the beginning of the studied time period.
A date marking the end of the studied time period.
A duration fixing the wanted granularity.
An vector of integers containing the stat_units of the wanted data. Default: NULL (means every stat_unit)
A function to aggregate data. Default: mean_aggregate
A function to impute data. Default: linear_impute
A duration after which, if no data are found, no more will be imputed. Default: 5 * temporal_granularity
The part of analysr_env$measures that has been modified.