checkMinRate: Include only the risk factors that appear in x% of the data.

Description Usage Arguments Value Examples

View source: R/checkMinRate.R

Description

checkMinRate returns a logical value after evaluating an object whose existence is greater than a specified amount. Despite permitting any object class to be passed, only an object with a class of 'logical'will be evaluated.

Usage

1
checkMinRate(x, min_rate = 0.01)

Arguments

x

The object to be evaluated.

min_rate

The threshold for permissable risk factor found in patient population. Defaults to 1%.

Value

Returns variables that meet the min_rate criteria.

Examples

1
2
3
data <- data.frame(diab = c(T, T, F, F), obese = c(T, F, T, F), site = c("A", "B", "C", "D"),
     bmi = c(16, 18, 20, 22))
checkMinRate(data$diab, min_rate = .45)

West-End-Statistics/r-library-vakdr documentation built on Dec. 18, 2021, 7:16 p.m.