wtd_lg_rate: Weighted Logical Rate Calculation

Description Usage Arguments Value

View source: R/weighted_aggregators.R

Description

Calculate a rate using a logical field, with TRUE as the numerator, and TRUE/FALSE as the denominator. This excludes NA values. When provided, the results of each are multiplied by the cases parameter, which allows us to appropriately scale the calculations for our reduced record data sets that are included in the package'

Usage

1
wtd_lg_rate(logical_column, weight_column = "cases", na.rm = FALSE)

Arguments

logical_column

a name of a logical table field name that will be aggregated

weight_column

a value that should be applied to the result in order to simulate

na.rm

a logical indicator of whether NA values should be removed prior to aggregation a number of records with this result.

Value

a formula that can be executed in a dplyr summarize statement


Mikuana/vitalstatistics documentation built on May 7, 2019, 4:57 p.m.