Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

many-dichotomous-variables #12

Open
noamross opened this issue Mar 22, 2015 · 0 comments
Open

many-dichotomous-variables #12

noamross opened this issue Mar 22, 2015 · 0 comments

Comments

@noamross
Copy link
Owner

https://github.com/noamross/zero-dependency-problems/blob/master/R/many-dichotomous-variables.md

I have a dataframe with around 8000 rows. Variable X is a categorical variable with values ranging from 1 to 200. I want to create 200 dichotomous variables (0/1) based on X.

Thus X001 == 1 if X == 1; & X001 == 0 if X !=1. Any suggestions how to do this?

Thanks for your time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant