BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
cken123
Calcite | Level 5

I am trying to create a histogram with the following code 

 

Options pagesize=45;
Data Fish;
Input time quality @@;
Cards;
0 8.5
0 8.4
3 7.9
3 8.1
6 7.8
6 7.6
9 7.3
9 7.0
12 6.8
12 6.7
;
Run;
Proc Reg;
Model quality=time;
plot quality*time='*';
plot R.*P.='?';
plot R.*time='@';
output out=error R=resid;
Run;
Proc Chart;
vbar resid;
run;

 

The following errors occur 

 

ERROR: Appendage SASXGANO not found, unable to produce graphics.
NOTE: The SAS System stopped processing this step because of errors.
WARNING: The data set WORK.ERROR may be incomplete. When this step was stopped there were 0 observations and 0 variables.
WARNING: Data set WORK.ERROR was not replaced because this step was stopped.
NOTE: PROCEDURE REG used (Total process time):
real time 10.66 seconds
cpu time 2.24 seconds
 
 
 
96 Proc Chart;
97 vbar resid;
ERROR: Variable RESID not found.
98 run;
 
Any suggestions on how to fix this?
  

 

1 ACCEPTED SOLUTION

Accepted Solutions
DanH_sas
SAS Super FREQ

I appears that ODS Graphics is somehow turn off in your case. Also, use PROC SGPLOT instead of PROC CHART. Try this:

 

ods graphics on;

Proc Reg;
Model quality=time;
plot quality*time='*';
plot R.*P.='?';
plot R.*time='@';
output out=error R=resid;
Run;

Proc sgplot data=error;
vbar resid;
run;

Hope this helps!

Dan

View solution in original post

1 REPLY 1
DanH_sas
SAS Super FREQ

I appears that ODS Graphics is somehow turn off in your case. Also, use PROC SGPLOT instead of PROC CHART. Try this:

 

ods graphics on;

Proc Reg;
Model quality=time;
plot quality*time='*';
plot R.*P.='?';
plot R.*time='@';
output out=error R=resid;
Run;

Proc sgplot data=error;
vbar resid;
run;

Hope this helps!

Dan

SAS INNOVATE 2024

Innovate_SAS_Blue.png

Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Get the $99 certification deal.jpg

 

 

Back in the Classroom!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 782 views
  • 0 likes
  • 2 in conversation