CDC-DNPAO / CDCAnthro

10 stars 6 forks source link

Specifying sex variable #3

Closed kjg321 closed 1 year ago

kjg321 commented 1 year ago

This package has been very useful to me already. I got all NA results (except for age, wt, and bmi) until I figured out that it wasn't recognizing the column labeled "SEX" -- Everything worked after copying that into a new "sex" column. As a feature request, being able to specify the sex column as for the other parameters (or recognizing column independent of capitalization) would make this smoother.

As an undocumented feature (not the buggy kind): when I used input from a data.table, the output was also a data.table and I could subset the columns of interest using that syntax.

CDC-DNPAO commented 1 year ago

thanks - I've changed the function so that it gives an informative error message if 'sex', 'SEX' or 'Sex' is not present. Any of these names for a child's sex is OK