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

I'm trying to specify three repeated factors in Proc Mixed.  I'm able to specify one or two repeated factors depending on the covariance structure specified in the Repeated statement.  (Two repeated factors seems to require Type=un@cs or Type=un@un.)  However, I've had no success with three repeated factors.  Is it a matter of specifying the appropriate covariance structure, or does Proc Mixed not handle more than 2 repeated factors?

Below is the code I'm running.  The data is stacked as it should be.

proc mixed data=subject5;

class subject pricea priceb pricec;

model rate=pricea|priceb|pricec/ddfm=kr;

repeated pricea priceb pricec/subject=subject type=un@un;

run;

Thanks for any help anyone can provide.

1 ACCEPTED SOLUTION

Accepted Solutions
Ryan
Calcite | Level 5

I would consider writing the following REPEATED statement:

repeated pricea*priceb*pricec / subject=subject type=un;

Ryan

View solution in original post

4 REPLIES 4
Ryan
Calcite | Level 5

I would consider writing the following REPEATED statement:

repeated pricea*priceb*pricec / subject=subject type=un;

Ryan

SteveDenham
Jade | Level 19

This is undoubtedly the only way to get after this, unless there is a natural nesting of some of the factors.  I would be curious about the design that gives rise to this--would it be possible to reparameterize so that this could be fit in a less "bulky" form.  I worry about the following--suppose each of the prices has three levels.  The three-way interaction will have 27 levels, and an unstructured matrix will require estimating 351 parameters.  It is going to take a large dataset to get good estimates for that many parameters.

Steve Denham

DannyWeathers
Calcite | Level 5

Steve,  You guessed right.  Each price did have 3 levels.  Each subject evaluated 27 product "bundles."  Each bundle contained the same 3 products, and the prices of each product were manipulated at 3 levels each.  Subjects rated the attractiveness of the overall bundle.  I'll consider ways to reparameterize the model, but our goal is to test for possible interactions between the prices.

Thanks for your help.

Danny

SteveDenham
Jade | Level 19

Ryan's suggestion should work, but you will need about 10 times as many records as parameters to be able to get it to converge to anything reasonable.

(And a fairly intense computing platform).

Steve Denham

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is ANOVA?

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.

Discussion stats
  • 4 replies
  • 1700 views
  • 4 likes
  • 3 in conversation