min_n: min_n

Description Usage Arguments Value See Also Examples

View source: R/min_n.R

Description

Keep variables with a minimum of n samples

Usage

1
min_n(df, n = 200, skip = NULL, only = NULL)

Arguments

df

data frame

n

minimum sample size desired

skip

list of column names that are not filtered

only

list of column names that are filtered, any others are skipped

Value

data frame containing only those variables with at least n samples

See Also

Other filter functions: colfilter, get_binary, get_categorical, get_check, get_continuous, min_cat_n, remove_incomplete_obs, remove_outliers, rowfilter

Examples

1
2
3
require(NHANES)
data(NHANES)
ncol(min_n(NHANES, n = 1000))

HallLab/clarite documentation built on Oct. 27, 2020, 6:27 p.m.