BookmarkSubscribeRSS Feed
Fettah
Fluorite | Level 6

The title says it all, I'm trying to generate a scatterplot similar what PRISM can do. Has anyone tried to do something similar in SAS?

http://i.stack.imgur.com/z53zB.gif

Trying a categorical x-axis only creates a column of dots with the corresponding values.

proc sgplot data=sashelp.class;

  scatter x=sex y = height

  /MARKERATTRS  =(symbol=circlefilled);

  run;

I appreciate your feedback.

2 REPLIES 2
ballardw
Super User

You may have to explain what that graph represents and the pieces. No legend makes it very hard to guess. It looks like it might be a scatter plot overlayed on a box plot but the content isn't very obvious without much more information.

Include data used to make your example as we have no clue what your data structure would be and we can't even make a test data set to try to match your output.

Jay54
Meteorite | Level 14

JITTER is supported at SAS 9.4.  Jitter kicks in when the data is very dense.  But it may not kick in for sashelp.class.

proc sgplot data=sashelp.cars(where=(type ne 'Hybrid'));

  scatter x=type y=mpg_city / jitter

          MARKERATTRS=(symbol=circlefilled);

  run;

We are considering other types of jitter and options.  Please feel free to provide your suggestions.

jitter_cars_SG.png

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