BookmarkSubscribeRSS Feed
echoli
Obsidian | Level 7

Hi all,

 

I want to have a boxplot figure below, in the topleft area (mean area) I want to add some results analysized by myself, for example, I want to add "E1 vs E2  E2 VS E3" in the rectangle (mean area). I tried to use inset statement in the proc boxplot, but shows syntax error. 

Any idea?

 

Thanks

boxplot.png

3 REPLIES 3
Reeza
Super User

Show your code and log

echoli
Obsidian | Level 7

Hi,

I know my code is wrong. I was wondering if there is a way to add some text in the figure?

 

1893 proc boxplot data=box;

1894 plot lin_*group /
1895 nohlabel;
1896 label lin_ = 'No. of Lin+';
1897 inset P-Value / height=5 cfill=blank header='' pos=nw;
-
22
76
ERROR 22-322: Syntax error, expecting one of the following: DATA, MAX, MEAN, MIN, NMAX, NMIN, NOBS, STDDEV.
ERROR 76-322: Syntax error, statement will be ignored.
1898 run;

 

Thanks,

Chen

Jagadishkatam
Amethyst | Level 16

you should try the data option in the inset statement as below, in the position option in place of the x and y coordinates. Please specify the x and y axis where you want to have the box positioned.

 

also p-value is not a variable name, could you please check the p-value variable name and mention the same in place of p-value.

 
proc boxplot data=box;

plot lin_*group /
nohlabel;
label lin_ = 'No. of Lin+';
inset P-Value / height=5 cfill=blank header='E1 vs E2  E2 VS E3' position=(x,y) data;

quit;

run;

 

 

Thanks,
Jag

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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
  • 3 replies
  • 1708 views
  • 0 likes
  • 3 in conversation