Learn R Programming

climatehealth (version 1.0.0)

descriptive_stats: Save descriptive statistics

Description

Generates summary statistics for climate and health data and saves them to the specified file path.

Usage

descriptive_stats(data, variables, bin_width = 5, output_dir = ".")

Value

Prints summary statistics and a histogram of the the outcome variable

Arguments

data

Dataframe containing a daily time series of climate and health data

variables

Character or character vector with variable to produce summary statistics for. Must include at least 1 variable.

bin_width

Integer. Width of each bin in a histogram of the outcome variable. Defaults to 5.

output_dir

Character. The directory to output descriptive stats to. Must exist and will not be automatically created. Defaults to ".".