Hi,
I performed a regression with proc GLM using these commands (the dataset is attached):
proc glm data=act.taux_activite;
class education(ref='Aucun') region(ref='NIAME') sexe(ref='Masculin') grage(ref='30_34');
model logittaux = grage education region sexe grage*sexe grage*education/solution;
output out=test predicted=plogittaux;
run;
I want predicted values, so I added the statement output out=test predicted=plogittaux;
I manage to have parameters, but for I reason I don't get, the procedure keeps running, and the output dataset "test" is never created.
Is something wrong with my codes?
GLM is an interactive procedure and needs a quit; statement to end. Your code does not have that, so it might be that your procedure stays active.
EG usually takes care of that by issuing the "magic" sequence designed to end everything for good:
;*';*";*/;quit;run;
I ran your code with the data in datalines, and immediately got this log:
27 data taux_activite; 28 infile datalines dlm=',' truncover; 29 input Region :$5. grage :$5. Sexe :$10. education :$10. taux logittaux; 30 datalines; NOTE: The data set WORK.TAUX_ACTIVITE has 832 observations and 6 variables. NOTE: DATA statement used (Total process time): real time 0.01 seconds cpu time 0.01 seconds 863 ; 864 run; 865 866 proc glm data=taux_activite; 867 class education(ref='Aucun') region(ref='NIAME') sexe(ref='Masculin') grage(ref='30_34'); 868 model logittaux = grage education region sexe grage*sexe grage*education/solution; 869 output out=test predicted=plogittaux; 870 run; 871 quit; NOTE: The data set WORK.TEST has 832 observations and 7 variables. NOTE: The PROCEDURE GLM printed pages 1-4. NOTE: PROCEDURE GLM used (Total process time): real time 0.08 seconds cpu time 0.03 seconds
and got control back with a properly finished procedure.
GLM is an interactive procedure and needs a quit; statement to end. Your code does not have that, so it might be that your procedure stays active.
EG usually takes care of that by issuing the "magic" sequence designed to end everything for good:
;*';*";*/;quit;run;
I ran your code with the data in datalines, and immediately got this log:
27 data taux_activite; 28 infile datalines dlm=',' truncover; 29 input Region :$5. grage :$5. Sexe :$10. education :$10. taux logittaux; 30 datalines; NOTE: The data set WORK.TAUX_ACTIVITE has 832 observations and 6 variables. NOTE: DATA statement used (Total process time): real time 0.01 seconds cpu time 0.01 seconds 863 ; 864 run; 865 866 proc glm data=taux_activite; 867 class education(ref='Aucun') region(ref='NIAME') sexe(ref='Masculin') grage(ref='30_34'); 868 model logittaux = grage education region sexe grage*sexe grage*education/solution; 869 output out=test predicted=plogittaux; 870 run; 871 quit; NOTE: The data set WORK.TEST has 832 observations and 7 variables. NOTE: The PROCEDURE GLM printed pages 1-4. NOTE: PROCEDURE GLM used (Total process time): real time 0.08 seconds cpu time 0.03 seconds
and got control back with a properly finished procedure.
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.