BookmarkSubscribeRSS Feed
mcmaxwell
Fluorite | Level 6

Hi everyone, 

Is there a simple way to specify the maximum value to show on the Y axis in proc sgplot? I'm using the code below to make a simple bar graph and it returns a graph where the Y axis goes up to 15, but I would like it to go up to 20. 

 

ods graphics on / width=3.5in height=4.5in;  
proc sgplot data=new;        
	vbar cPLTL / response=percent group =cPLTL groupdisplay=cluster barwidth=.5;
	styleattrs datacolors=(CXFF8000 CX0000FF); 
	yaxis label="Percent of unsuccessful students";   
	xaxis display=(nolabel); 
	run;      
ods graphics off 
2 REPLIES 2
PaigeMiller
Diamond | Level 26
yaxis label="Percent of unsuccessful students" values=(0 to 0.2 by 0.05);
--
Paige Miller
Ksharp
Super User
yaxis label="Percent of unsuccessful students" max=20 ;

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 496 views
  • 0 likes
  • 3 in conversation