noNAs: Succinctly select complete rows from a dataframe

View source: R/misc_and_utility.R

noNAsR Documentation

Succinctly select complete rows from a dataframe

Description

Succinctly select complete rows from a dataframe.

Usage

noNAs(df, rows = NULL, cols = NULL, drop = TRUE)

Arguments

df

an data.frame() to select on

rows

Rows to keep (optional, incomplete rows still discarded)

cols

Cols to keep

drop

Whether to return a vector when only 1 column is selected (default TRUE)

Value

  • Complete rows and (optionally) selected columns

See Also

Other Data Functions: prolific_check_ID(), umxFactor(), umxHetCor(), umx_as_numeric(), umx_cont_2_quantiles(), umx_lower2full(), umx_make_MR_data(), umx_make_TwinData(), umx_make_fake_data(), umx_make_raw_from_cov(), umx_merge_randomized_columns(), umx_polychoric(), umx_polypairwise(), umx_polytriowise(), umx_read_lower(), umx_read_prolific_demog(), umx_rename(), umx_reorder(), umx_score_scale(), umx_select_valid(), umx_stack(), umx

Examples

tmp = mtcars
tmp[2,1] = NA
noNAs(tmp, cols="mpg")
noNAs(tmp, cols="mpg", drop = FALSE)
noNAs(tmp) # no Mazda RX4 Wag


umx documentation built on Sept. 21, 2022, 9:07 a.m.

Related to noNAs in umx...