SAS Studio

Write and run SAS programs in your web browser
BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.

The question i want to solve is;

Make a scatterplot and portrays how weight (wt in x-axis) and height (ht
in y-axis) differs between genders (sex).Confirm your conclusions with a histogram and a comparative box plot.

 

I have made the scatterplot however am unsure how to do the second bit. Would I need 2 separate box plots and histograms to do this?

1 ACCEPTED SOLUTION

Accepted Solutions
PaigeMiller
Diamond | Level 26

Box plots: one plot, two boxes (one for male and one for female)

 

Histogram: one plot, bars for males along side bars for females.

 

PROC SGPLOT will do both.

--
Paige Miller

View solution in original post

4 REPLIES 4
PaigeMiller
Diamond | Level 26

Box plots: one plot, two boxes (one for male and one for female)

 

Histogram: one plot, bars for males along side bars for females.

 

PROC SGPLOT will do both.

--
Paige Miller
laurenhosking
Quartz | Level 8
Brilliant so for boxplot I’d need 2 graphs one for weight and gender the other height and gender?
PaigeMiller
Diamond | Level 26

Both box plots and scatterplots have only one y-variable.

 

So you will need one box plot for height and another for weight. Same for histograms.

--
Paige Miller
laurenhosking
Quartz | Level 8
Fabulous so all together I’ll have on scatterplot. Height and weight on each axis and a colour change for gender. Then 2 separate box plots and 2 histograms.

sas-innovate-wordmark-2025-midnight.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.


Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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