I need to calculate the Mean Age of a population (descriptive statistics) by gender and product. How can I do it with Proc Mean? Or probably with PROC UNIVARIATE?
Proc Mean or Proc summary (they're basically the same proc but means produces printed output by default and summary doesn't) use a by or class statement to set up your groupings and a var statement to specify your age variable. On your output statement you'll want the MEAN= statistic.
Enjoy (And if you use CLASS, remember to use NWAY!)
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.