My code is as follows:
proc sgplot data = demo;
styleattrs datacontrastcolors=(G R Olive Steel Gold Cyan)
datasymbols=(circlefilled);
scatter x = ss y = mm / group=en;
xaxis label= "SS" values = (600 to 900 by 25);
yaxis label= "MM" values = (-500 to 3000 by 500);
run;
This is causing my plot to remove all of the points that are not specified in the values statement. How do I avoid overlap on the x-axis but still include all of the points? I'm not sure what I am doing wrong.
Is your x variable discrete? Try JITTER=UNIFORM option on the SCATTER plot statement.
I just figured out my (very silly) mistake and went to remove this post but it already had a reply! Thank you so much. My x variable wasn't numeric- I don't know why I didn't think to check that first. I fixed that and all is well.
Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.
Register today!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.