I remember @Rick_SAS plot such kind of graph in his blog .
The terms to search for are "binning" or "2-d binning". In particular, it sounds like you want equal-width binning.
Your instructor might have mentioned ways to bin the data. There are many ways to do this. Including the DATA step, PROC IML, PROC KDE, PROC FORMAT+PROC FREQ, and more. Your instructor might have given a hint about which method you should use, so check with him or her.
More information that you will need is discussed in The Essential Guide to Binning in SAS.
If your instructor did not indicate a preference for this assignment, PROC FORMAT and PROC FREQ might be the easiest combination. If you have never used PROC FORMAT, then maybe use PROC KDE and the OUT= option on the BIVAR statement. For PROC KDE, the first step would be something like this example (which uses example data)
proc kde data=sashelp.bweight;
bivar MomWtGain(ngrid=7) Weight(ngrid=7) / out=kdeout;
run;
I will leave the rest of the assignment to you. Good luck.
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.