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

Hi All,

 

I'm using Proc SGPLOT to create several VBAR graphs. I want to have consistency between them all and to show a 500 interval on the Y axis and a max interval of 4,000.

 

Apologies for the test data - I can't get the dates to go in properly - any help to get this right would be appreciated.

data test;
 Input WEEK_END_DT   $ Count;
 Datalines;
2017-07-09 2738
2017-07-16 3361
2017-07-23 3567
2017-07-30 3421
2017-08-06 3382
2017-08-13 3216
2017-08-20 2697
2017-08-27 2475
2017-09-03 2327
2017-09-10 2434
2017-09-17 2497
2017-09-24 2455
2017-10-01 2510
2017-10-08 1814
2017-10-15 2106
2017-10-22 2456
2017-10-29 1932
2017-11-05 1986
2017-11-12 1754
2017-11-19 1635
2017-11-26 1597
2017-12-03 1708
2017-12-10 1439
2017-12-17 1379
2017-12-24 1399
2017-12-31 611
2018-01-07 1376
2018-01-14 1640
2018-01-21 1745
2018-01-28 1422
2018-02-04 1872
2018-02-11 1996
2018-02-18 1456
2018-02-25 1007
2018-03-04 965
2018-03-11 992
2018-03-18 906
;
Run;

 

 

 

Proc SGPlot data=Test;
	Title "AAA Count";
	VBar WEEK_END_DT / response=COUNT;
Run;

 

 

Any help appreciated.

 

Cheers

 

Dean

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

YAXIS or XAXIS statements control the appearance of the axis.

Try

 

Yaxis values=(0 to 4000 by 500);

View solution in original post

2 REPLIES 2
ballardw
Super User

YAXIS or XAXIS statements control the appearance of the axis.

Try

 

Yaxis values=(0 to 4000 by 500);

SAS Innovate 2025: Register Now

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!

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 18437 views
  • 1 like
  • 2 in conversation