CovidTimeseriesProvider: General covid processing

Description Super classes Methods

Description

General covid processing

General covid processing

Super classes

ukcovidtools::PassthroughFilesystemCache -> ukcovidtools::DataProvider -> CovidTimeseriesProvider

Methods

Public methods

Inherited methods

Method new()

New timeseries provider pipeline

Usage
CovidTimeseriesProvider$new(providerController, ...)
Arguments
providerController

the provider controller

...

for compatibility

Returns

the provider


Method setTruncation()

Usage
CovidTimeseriesProvider$setTruncation(listDays)

Method trimNAs()

Usage
CovidTimeseriesProvider$trimNAs(r0Timeseries)

Method complete()

Take a set of timeseries and add in missing dates as NAs. Preserves source, type, statistic differences in timeseries length. intially Fills all regions to be the same length but with trim trailing NAs

Usage
CovidTimeseriesProvider$complete(covidTimeseries)
Returns

a covidTimeseriesFormat dataframe


Method completeAllRegions()

Take a set of timeseries and add in missing dates as NAs. Preserves source, type, statistic differences in timeseries length. intially Fills all regions to be the same length but with trim trailing NAs

Usage
CovidTimeseriesProvider$completeAllRegions(covidTimeseries)
Returns

a covidTimeseriesFormat dataframe


Method fillAbsent()

Usage
CovidTimeseriesProvider$fillAbsent(covidTimeseries, completeDates = FALSE)

Method fillAbsentAllRegions()

Take a set of regional timeseries, finds the full list of regions and the whole timeseries and fills any missing values with zero (if incidence) or the previous value (if cumulative) explicitly filling in missing values. This is suitable for use for a incidence derived from a line list where some dates and regions will not be observed

Usage
CovidTimeseriesProvider$fillAbsentAllRegions(covidTimeseries)
Returns

a covidTimeseriesFormat dataframe


Method fillAbsentByRegion()

Take a set of timeseries and fills any missing values with zero (if incidence) or the previous value (if cumulative) explicitly filling in zeros for missing values. This is suitable for use for a incidence derived from a line list where some dates will not be observed. It does not enforce that something has been observed in all regions.

Usage
CovidTimeseriesProvider$fillAbsentByRegion(covidTimeseries)
Returns

a covidTimeseriesFormat dataframe


Method fixDatesAndNames()

Take a set of timeseries and fixes any non standard names, truncates time series by truncate days. intially Fills all regions to be the same length but with trim trailing NAs

Usage
CovidTimeseriesProvider$fixDatesAndNames(covidTimeseries, truncate = NULL)
Returns

a covidTimeseriesFormat dataframe


Method timeseriesQA()

Check timeseries conforms

Usage
CovidTimeseriesProvider$timeseriesQA(covidTimeseries)

Method describeErrors()

Usage
CovidTimeseriesProvider$describeErrors(covidTimeseries, valueVar = "value")

Method describe()

Usage
CovidTimeseriesProvider$describe(covidTimeseries, ...)

Method clone()

The objects of this class are cloneable with this method.

Usage
CovidTimeseriesProvider$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.


terminological/uk-covid-datatools documentation built on June 24, 2021, 8:16 p.m.