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

I want to split label for each panel header,  

proc format;

VALUE $ CHE
'a' ="AAAAAAAAAAAAA(*ESC*)(100mg N=638, 200mg N=320)"
'b' ="BBBBBBBBBBBBBB(*ESC*){unicode '000a'x}(100mg N=638, 200mg N=320)"
'c' ="CCCCCCCCCCCCCCC(*ESC*){unicode '000a'x}(100mg N=638, 200mg N=320)"
'd' ="DDDDDDDDDDDDDD (pompholyx)(*ESC*){unicode '000a'x}(100mg N=638, 200mg N=320)"
'e' ="EEEEEEEEEEEE(*ESC*){unicode '000a'x}(100mg N=638, 200mg N=320)"
;

run;

 

proc sgpanel data=Test_all noautolegend;
format EPTCD $Ept. subgroup $CHE.;
panelby Subgroup/layout=panel spacing=0 novarname columns=2 rows=3 sort=ASCENDING ;

styleattrs datacontrastcolors=(black);
scatter x=difference y=EPTCD / filledoutlinedmarkers group=Subgroup grouporder=Data xerrorlower=lcl xerrorupper=ucl
markerfillattrs=(color= blue) markerattrs=(symbol=squarefilled) markeroutlineattrs=(color=blue) ;
REFLINE 0 / axis=X;
inset txt /nolabel POSITION=bottomright TEXTATTRS=(Family=Arial Size=6 ) ;
colaxis label="Difference (95% CI)" values=(-20 -10 0 10 20 30 40 50 60 70) offsetmin=0.05 offsetmax=0.05;
rowaxis colorbands=odd label=" " offsetmax=.2 DISCRETEORDER=data reverse ;

run;

1 ACCEPTED SOLUTION

Accepted Solutions
whymath
Barite | Level 11

How about using two variables in panelby statement?

proc sgpanel data=sashelp.prdsale;
  where product in ("CHAIR" "SOFA");
  panelby year product/ spacing=5 novarname noheaderborder;
  vline month / response=actual;
run;

1.png

 

View solution in original post

1 REPLY 1
whymath
Barite | Level 11

How about using two variables in panelby statement?

proc sgpanel data=sashelp.prdsale;
  where product in ("CHAIR" "SOFA");
  panelby year product/ spacing=5 novarname noheaderborder;
  vline month / response=actual;
run;

1.png

 

sas-innovate-2026-white.png



April 27 – 30 | Gaylord Texan | Grapevine, Texas

Registration is open

Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—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
  • 1 reply
  • 1508 views
  • 0 likes
  • 2 in conversation