BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Divinesking
Fluorite | Level 6

Hello everyone,

 

I am trying to understand how the joint F value from proc mixed using lsmestimate option is being calculated. An example data, sas

data test;
input Y visitno subid;
datalines;
7 1 1
9 1 2
8 1 3
7 2 1
8 2 2
6 2 3
;

 

proc mixed data=test ;
class visitno subid;
model y = visitno/solution outp=pred ;
repeated visitno /type=un subject=subid;
*contrast 'visitno' [1 1], [1 2];
lsmestimate visitno [1 1], [1 2]/joint(chisq) cl e;
run;

 

Least Squares Means Estimates 
Effect Label Estimate Standard Error DF t Value Pr > |t| Alpha Lower Upper 
visitno Row 1 8.0000 0.5774 2 13.86 0.0052 0.05 5.5159 10.4841 
visitno Row 2 7.0000 0.5774 2 12.12 0.0067 0.05 4.5159 9.4841 



F Test for Least Squares Means Estimates 
Effect Num DF Den DF Chi-Square F Value Pr > ChiSq Pr > F 
visitno 2 2 228.00 114.00 <.0001 0.0087 


 

Can someone help me understand how the F Value of 114 is derived?

 

Thank you for your help.

 

Best,

 

Divine

1 ACCEPTED SOLUTION
5 REPLIES 5
PaigeMiller
Diamond | Level 26

Please click on the {i} icon and paste the output into the window that appears. This will maintain the formatting of your output, and make it readable.

--
Paige Miller
PaigeMiller
Diamond | Level 26

The Chi-squared value is computed to be 228, so the F-value is 228/2 = 114.

 

For future reference, I wanted you to copy the TEXT from the LISTING window and paste it into the {i} window. If you copy the HTML, it still isn't very readable. If you don't have a LISTING window, then a screen capture of the HTML is fine.

--
Paige Miller
Divinesking
Fluorite | Level 6

Thank you PaigeMiller. 

 

 

 

Divinesking
Fluorite | Level 6

Thank you again!

hackathon24-white-horiz.png

The 2025 SAS Hackathon Kicks Off on June 11!

Watch the live Hackathon Kickoff to get all the essential information about the SAS Hackathon—including how to join, how to participate, and expert tips for success.

YouTube LinkedIn

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 5 replies
  • 1636 views
  • 2 likes
  • 2 in conversation