I'm running SAS on demand for academics.
My question how to make the code file= statement work? I'm getting the following error in the LOG: ERROR: HPSPLIT was unable to open the code file for output.
ods graphics on;
proc hpsplit data=Wine CVCC
seed=123;
class Cultivar;
model Cultivar = Alcohol Malic Ash Alkan Mg TotPhen Flav
NFPhen Cyanins Color Hue ODRatio Proline;
code file ="winecode.sas";
grow entropy;
prune costcomplexity;
run;
This CODE statement worked for me. The "home/blund0" is a folder in the SAS on Demand for Academics file system:
proc hpsplit data=Wine CVCC
seed=123;
class Cultivar;
model Cultivar = Alcohol /*Malic*/ Ash /*Alkan Mg TotPhen Flav
NFPhen Cyanins Color Hue ODRatio Proline*/;
code file ="/home/blund0/HPSPLIT/winecode.sas";
grow entropy;
prune costcomplexity;
run;
I would start with setting the file in home directory:
file ="~/winecode.sas"
Bart
This CODE statement worked for me. The "home/blund0" is a folder in the SAS on Demand for Academics file system:
proc hpsplit data=Wine CVCC
seed=123;
class Cultivar;
model Cultivar = Alcohol /*Malic*/ Ash /*Alkan Mg TotPhen Flav
NFPhen Cyanins Color Hue ODRatio Proline*/;
code file ="/home/blund0/HPSPLIT/winecode.sas";
grow entropy;
prune costcomplexity;
run;
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.