View source: R/subset_mortality_period.R
subset_mortality_period | R Documentation |
Intended to be used on a standardized mortality dataset which additionally captured dates of different demographic events such as joins, lefts, births and deaths. It will dynamically subset the data between a specified start and end of the recall period, and either include or exclude people, and calculate their estimated person time observed.
subset_mortality_period(df, start_date, end_date)
df |
Inputs a dataframe that has already been standardized by the format_current_census_mortality function. |
start_date |
Inputs a character value of a date of the start of the recall period, in a format like YYYY-MM-DD. |
end_date |
Inputs a character value of a date of the end of the recall period, in a format like YYYY-MM-DD. |
Returns a subsetted mortality dataset.
## Not run: subset_mortality_period(df = mymortalitydata, start_date = "2020-04-24", end_date = "2021-05-15")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.