Last chance! 50% off unlimited learning
Sale ends in
Convert each column of a dataframe to numeric
umx_as_numeric(df, force = FALSE)
A data.frame
to convert
Whether to force conversion to numeric for non-numeric columns (defaults to FALSE)
- data.frame
Other Data Functions: umxCovData
,
umxFactor
, umxHetCor
,
umxPadAndPruneForDefVars
,
umx_cont_2_quantiles
,
umx_cov2raw
, umx_long2wide
,
umx_lower2full
,
umx_make_MR_data
,
umx_make_TwinData
,
umx_make_bin_cont_pair_data
,
umx_make_fake_data
,
umx_merge_CIs
,
umx_read_lower
, umx_reorder
,
umx_residualize
, umx_round
,
umx_scale_wide_twin_data
,
umx_scale
, umx_swap_a_block
,
umx_wide2long
, umx
# NOT RUN {
df = mtcars
# make one variable non-numeric
df$mpg = c(letters,letters[1:6]); str(df)
df = umx_as_numeric(df)
# }
Run the code above in your browser using DataLab