How to create method/macro about create dummy variable from categorical data fields ?
- - Nominal to Numerical (Unique Integer)
my previous method, I use R command in R Tool ., but, i want to easier way to auto generate dummy variable.
Thanks
Solved! Go to Solution.
I would suggest using the following sequence to get some dummy variables:
1. Use Summarize Tool to create a list of your variables
2. Use RecordID to create a numeric value for each variable in the list
3. Use a Find & Replace tool to replace the original value with the new RecordID from your Summarized list
Repeat for each variable you wish to replace, and will work for any number of variables!
EDIT: Added a sample workflow for a few of the variables.
Cheers,
NJ
In my attached solution, I used a Tile tool to create a unique recordID/numeric assignment for each variable and replaced them in the original set.
The resulting categorical assignment are not Dummy variables, who strictly take a value of 0 or 1. Dummy variables would be useful for statistic analysis, so I've also attached that solution.
@NicoleJohnson
Well Done, Good Solution ^__^
Thanks madam
@CharlieS
Oh! Very Nice. Best Solution.
Thanks sir