Download presentation
Presentation is loading. Please wait.
Published byMartin Knudsen Modified over 5 years ago
1
Let’s continue to review some of the statistics you’ve learned in your first class:
Bivariate analyses (two variables measured at a time on each observation) are done both graphically and numerically. There are 3 ways to look at the bivariate analyses: categorical vs categorical (use PROC FREQ and PROC GCHART) categorical vs quantitative (use PROC UNIVARIATE with the BY statement on the categorical variable - also PROC BOXPLOT and PROC TTEST & NPAR1WAY) quantitative vs quantitative (use PROC GPLOT, PROC CORR, PROC REG)
2
/* for two categorical variables… */
PROC FREQ; TABLES marsh*form; run; quit; PROC GCHART; VBAR marsh/ group=form; run; quit; /* what does the next one do? */ PROC GCHART; VBAR marsh/ sumvar=plantht type=mean group=form; run; quit; /* now one categorical, one quantitative */ PROC SORT; BY marsh; PROC UNIVARIATE DATA=padgett PLOT; VAR plantht; BY marsh; run; quit; /* this gives side-by-side BOXPLOTS - can also use PROC BOXPLOT after SORTing */ PROC BOXPLOT DATA=padgett; PLOT plantht*marsh; run; quit;
3
Now what about two quantitative variables??
/* first plot the two */ PROC GPLOT DATA=padgett; PLOT totmass*plantht; run; quit; /* get the correlation coefficients */ PROC CORR; run; quit; /*this gives descriptive statistics and correlations of all numeric statistics*/ PROC REG; MODEL totmass = plantht; PLOT totmass*plantht; run; quit; /* there are many options to REG */
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.