Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Home
- /
- Analytics
- /
- Stat Procs
- /
- How to draw interaction figure

Options

- RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

🔒 This topic is **solved** and **locked**.
Need further help from the community? Please
sign in and ask a **new** question.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Posted 06-29-2018 02:31 PM
(1261 views)

I want to maintain all the results that come out after running following codes. However, I want to modify the codes to generate a figure of interaction of the independent variables. Could you please help? Thank you.

proc glimmix data=a1.prediss1 plots=residualpanel(conditional marginal);

class phase_info1 Phoneme_stress subject;

model ResidualError_Sum= phase_info1|Phoneme_stress/solution dist=gamma;

output out=a1.predata pred=pred resid=r;

random intercept phase_info1|Phoneme_stress/ subject=subject;

run;

1 ACCEPTED SOLUTION

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Try

```
lsmeans phase_info1*Phoneme_stress / plot=meanplot(sliceby=phase_info1 join cl);
```

Before you go too far down this path, be sure that your RANDOM statement is specifying what you want it to specify: it currently identifies a variance among subjects, a variance among units defined by subject * phase_info1, a variance among units defined by Phoneme_stress * subject, and a variance among units defined by phase_info1 * Phoneme_stress * subject. Maybe that makes sense for your design, but maybe it does not.

The name of the response variable (ResidualError_Sum) is a bit suspicious. Is your response a residual from some other model that you've fit?

2 REPLIES 2

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Try

```
lsmeans phase_info1*Phoneme_stress / plot=meanplot(sliceby=phase_info1 join cl);
```

Before you go too far down this path, be sure that your RANDOM statement is specifying what you want it to specify: it currently identifies a variance among subjects, a variance among units defined by subject * phase_info1, a variance among units defined by Phoneme_stress * subject, and a variance among units defined by phase_info1 * Phoneme_stress * subject. Maybe that makes sense for your design, but maybe it does not.

The name of the response variable (ResidualError_Sum) is a bit suspicious. Is your response a residual from some other model that you've fit?

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Thank you again, Sid.

Yes, the model includes phase_info1, Phoneme_stress, and phase_info1 * Phoneme_stress in the final equation in both fixed and random effects, because phase_info1 and Phoneme_stress are all first level variables and I am interested in the interaction of these two variables.

And no, my dependent variable is just an error measurement from acoustic signal, so it is nothing to do with stat analysis.

Thanks for checking.

Please let me know if anything else can be a problem. Thank you!

**Available on demand!**

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

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.