Hi. Is there a way in SAS to generate predicted values after running a random forest model? I've looked at the HPFOREST documentation and I don't see a way of doing this. I've done something similar with CART with Proc HPSPLIT, but I couldn't find a similar way to do it for Random Forests. Thank you.
You should be able to use the SCORE statement to create a data set with the predicted values for the training data: https://go.documentation.sas.com/doc/en/emhpprcref/15.2/emhpprcref_hpforest_syntax08.htm
Or you can use the SAVE statement to create an analytic store ("astore") file that allows you to score new data using that generated file in HP4SCORE: https://go.documentation.sas.com/doc/en/emhpprcref/15.2/emhpprcref_hpforest_syntax07.htm
and https://go.documentation.sas.com/doc/en/emhpprcref/15.2/emhpprcref_hp4score_toc.htm
Hope that helps.
You should be able to use the SCORE statement to create a data set with the predicted values for the training data: https://go.documentation.sas.com/doc/en/emhpprcref/15.2/emhpprcref_hpforest_syntax08.htm
Or you can use the SAVE statement to create an analytic store ("astore") file that allows you to score new data using that generated file in HP4SCORE: https://go.documentation.sas.com/doc/en/emhpprcref/15.2/emhpprcref_hpforest_syntax07.htm
and https://go.documentation.sas.com/doc/en/emhpprcref/15.2/emhpprcref_hp4score_toc.htm
Hope that helps.
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
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.