powered by
Merge valid entries from two columns
umx_select_valid(col1, col2, bothways = FALSE, data)
name of the first column
name of the second column
Whether to replace from 1 to 2 as well as from 2 to 1
The dataframe containing the two columns.
Updated dataframe
within()
Other Data Functions: 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_polychoric(), umx_polypairwise(), umx_polytriowise(), umx_read_lower(), umx_read_prolific_demog(), umx_rename(), umx_reorder(), umx_score_scale(), umx_stack(), umx
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_polychoric()
umx_polypairwise()
umx_polytriowise()
umx_read_lower()
umx_read_prolific_demog()
umx_rename()
umx_reorder()
umx_score_scale()
umx_stack()
umx
# NOT RUN { tmp = mtcars tmp$newDisp = tmp$disp tmp$disp[c(1,3,6)] = NA anyNA(tmp$disp) # column has NAs tmp = umx_select_valid("disp", "newDisp", data = tmp) anyNA(tmp$disp) # column repaired # }
Run the code above in your browser using DataLab