Programming the statistical procedures from SAS

Is there a way to get exact p-values from Tukey?

Accepted Solution Solved
Reply
Occasional Contributor
Posts: 6
Accepted Solution

Is there a way to get exact p-values from Tukey?

Hello,

I am a relatively novice SAS user (currently using SAS 9.4, remote) and have what I believe is a very basic question.  I have a data set (n=80) of patients with one of three cancers (prostate, lung, breast) and am comparing other serum measurements against their form of cancer.  For example: Is the mean serum,  albumin level different between patients with lung cancer and breast cancer, etc.  For this I am utilizing a one-way ANOVA with post hoc Tukey test to control for type one error.  Everything runs smoothly and I get the results I want but I would like to report the exact p-values between the multiple comparisons rather than just knowing they are significant (a<0.05) via asterisks.  Is there a way to do this?  Adding a lines statement before tukey does not give the p-value either.

Sample code (after data):

proc anova data=TotalINTSAS;

class cancer;

model albumin=cancer;

means cancer/tukey;

run;

Any help is appreciated!  Thanks.

-Alle


Accepted Solutions
Solution
‎08-21-2015 10:55 AM
Respected Advisor
Posts: 2,655

Re: Is there a way to get exact p-values from Tukey?

Shift over to PROC GLM so that you can use the LSMEANS statement (probably a good idea anyway as I would guess that your data are unbalanced per cancer type).

proc glm data=TotalINTSAS;

class cancer;

model albumin=cancer;

lsmeans cancer/stderr pdiff=all adjust=tukey;

run;

Steve Denham

View solution in original post


All Replies
Solution
‎08-21-2015 10:55 AM
Respected Advisor
Posts: 2,655

Re: Is there a way to get exact p-values from Tukey?

Shift over to PROC GLM so that you can use the LSMEANS statement (probably a good idea anyway as I would guess that your data are unbalanced per cancer type).

proc glm data=TotalINTSAS;

class cancer;

model albumin=cancer;

lsmeans cancer/stderr pdiff=all adjust=tukey;

run;

Steve Denham

Occasional Contributor
Posts: 6

Re: Is there a way to get exact p-values from Tukey?

Steve-

I appreciate your quick and helpful reply!  I ran the code you posted and it works quite well.  My data is almost balanced (prostate=25, breast=30, lung=25) but in the future I am sure it will not be so pretty thus this is a great trick to keep in my pocket!  Thanks again.

-Alle

☑ This topic is SOLVED.

Need further help from the community? Please ask a new question.

Discussion stats
  • 2 replies
  • 400 views
  • 0 likes
  • 2 in conversation