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

Currently I have my data as        Day_of Inception (values 1-31)     month (values 'Oct, Nov, Dec)        NBcount  (numbers from 0-100)         business type ( a, b, c, d....)

I can get the graph I want for one business type using


proc gplot data = graphtable (where= (business_type=a));

     plot totalNB*day_of_inception=month /hminor=0;

run;

Is there a way I can panel the graphs so that it produces individual graphs (each with three plots (one for each month)) for each business type?

If not I can create a macro loop to produce the plots but I then can't figure out how to change the titles to have the business type in them so that the graphs are labeled.

Thank you in advance,



1 ACCEPTED SOLUTION

Accepted Solutions
DanH_sas
SAS Super FREQ

See if this works for you:

proc sgpanel data = graphtable;

     by business_type;

     panelby month;

     scatter y=totalNB x=day_of_inception;

run;

View solution in original post

2 REPLIES 2
DanH_sas
SAS Super FREQ

See if this works for you:

proc sgpanel data = graphtable;

     by business_type;

     panelby month;

     scatter y=totalNB x=day_of_inception;

run;

Lucy1234
Calcite | Level 5

by business_type;    was exactly what I needed and it worked in the gplot.  Thank you very much.

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
  • 2 replies
  • 1342 views
  • 0 likes
  • 2 in conversation