BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
djbateman
Lapis Lazuli | Level 10

I am attempting to make a "waterfall" plot with the NEEDLE interpolation in PROC GPLOT.  My plot is divided into two different groups.  I wanted the positive group to be blue and the negative group to be red.  Here is what I have attempted:

axis1 label=(angle=90 'Best Percent Change in Lesion Size') order=(-100 to 150 by 50) minor=(n=4);

axis2 label=(' ') value=none major=none minor=none;

proc gplot data=waterfall;

     plot ploty1*n ploty2*n / overlay vaxis=axis1 haxis=axis2;

     symbol1 interpol=Needle value=none width=4 color=blue;

     symbol2 interpol=Needle value=none width=4 color=red;

run;

I am not at all familiar with annotations, but I am sure I could do something with that.  I just have no idea where to start.

This is not my full data, but here is an idea of how it looks:

brpercentposnegnploty1ploty2
2.564Positive12.564
2.083Positive22.083
1.333Positive31.333
0Positive40
-5.263Positive5-.263
-30Positive6-30
-31.429Positive7-31.429
-36.842Positive8-36.842
-40Positive9-40
-50Positive10-50
150Negative11150
142.857Negative12142.857
78.152Negative1378.152
58.065Negative1458.065
52.174Negative1552.174
-3.704Negative16-3.704
-4Negative17-4
-4.762Negative18-4.762
-7.143Negative19-7.143
-18.75Negative20-18.75
1 ACCEPTED SOLUTION

Accepted Solutions
GraphGuy
Meteorite | Level 14

Here's an example where I've used Proc Gchart and Annotate to create a waterfall chart - I think you can re-use this technique to get the graph you're wanting...

http://robslink.com/SAS/democd41/waterfall_anno.htm

http://robslink.com/SAS/democd41/waterfall_anno_info.htm

View solution in original post

1 REPLY 1
GraphGuy
Meteorite | Level 14

Here's an example where I've used Proc Gchart and Annotate to create a waterfall chart - I think you can re-use this technique to get the graph you're wanting...

http://robslink.com/SAS/democd41/waterfall_anno.htm

http://robslink.com/SAS/democd41/waterfall_anno_info.htm

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

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

View all other training opportunities.

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