Hi Guys
I'm too new to SAS.
I'm working on a project predicting a model.
I have designed my diagram as shown on the attachment.
When i run the program at the decision tree node I'm getting a run time error.
So i checked on the result logs (see attachement) and found that the variable has more than 32766 categorical values.
I dont know how to go about this. Any help will be appreciated.
Thanks guys.
Hello okbbachabi0 -
The Interval selection is grayed out if the variable is defined as character in the underlying SAS data set. The Interval selection is available only for numeric variables.
Solutions include:
- convert the character variable to a numeric variable
- return to the method that you used to create the SAS data set, and define the variable as numeric instead of character.
Have a great day.
I would suggest changing the variable to a numeric or continuous measure. It is unlikely to be categorical with that many levels.
Right right-click the dataset and select edit variables to change the type
Hi HEOR-Ryan
Thanks for the reply.
Do you mean to right click on the actual data set as that doesn't give me the option to edit the variables even?
How can I go about this conversion?
thanks
In either the Input Data node or a Metadata node inserted in your flow before Decision Tree, you can change the level of that variable to Interval to treat as continuous or to set the role to Rejected to exclude it from the model.
Hi WendyCzika
Thanks. I have tried what you said but when i clicked on the file import node to change the level. The interval is greyed out. From the metadata when I added to the flow doesn't allow me to change the level. I don't want to reject those variables as i need them for my prediction.
Any other advices?
Thanks
Hello okbbachabi0 -
The Interval selection is grayed out if the variable is defined as character in the underlying SAS data set. The Interval selection is available only for numeric variables.
Solutions include:
- convert the character variable to a numeric variable
- return to the method that you used to create the SAS data set, and define the variable as numeric instead of character.
Have a great day.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Use this tutorial as a handy guide to weigh the pros and cons of these commonly used machine learning algorithms.
Find more tutorials on the SAS Users YouTube channel.