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
- /
- Re: One way ANOVA outputs in SAS

Options

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

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

Posted 04-29-2021 08:45 AM
(735 views)

Hi all,

I'm running a one way ANOVA analysis in SAS based on the following code:

proc anova data=dt;

class SERINDEX;

model Value0USNumdec = SERINDEX;

run;

The output returns:

The SAS System |

The ANOVA Procedure

Dependent Variable: Value0USNumdec

Source DF Sum of Squares Mean Square F Value Pr > FModelErrorCorrected Total

4 | 0.00220000 | 0.00055000 | 27.50 | <.0001 |

20 | 0.00040000 | 0.00002000 | ||

24 | 0.00260000 |

R-Square Coeff Var Root MSE Value0USNumdec Mean

0.846154 | 0.912681 | 0.004472 | 0.490000 |

Source DF Anova SS Mean Square F Value Pr > FSERINDEX

4 | 0.00220000 | 0.00055000 | 27.50 | <.0001 |

As an R user, I'm used to get the DF, Variance component (VC), CV (as percentage), SD and Root MSE both for the model and for the error when I perform an one-way ANOVA analysis.

How can I specify this output in SAS? The user guide for Proc Anova has nothing on it. I also looked at the proc Varcomp or proc mixed procedures but they seem not to give the output I need as well.

4 REPLIES 4

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

You really ought to format your output so that it is readable, that will help us and thus you get better answers and quicker answers. For output, a screen capture is fine (and readable).

I'm used to get the DF, Variance component (VC), CV (as percentage), SD and Root MSE both for the model and for the error

I do not know what the "variance component (VC)" in a one-way ANOVA means. Can you explain/provide a formula?

The SD**2 is the "Mean Square" column. There is no such thing as a root MSE both for the model and for the error. It only exists for the error, and is shown. The DF and CV are shown.

--

Paige Miller

Paige Miller

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

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

I asked you to explain what VC means in a one-way ANOVA, or provide the formula, I don't see that.

Everything else you ask for is in the ANOVA output, or can be computed from the ANOVA output.

There is nothing in SAS that produces this exact output; but you can of course program something to produce this exact output (although I am skeptical that matching the R output appearance exactly is necessary, or worth the effort)

--

Paige Miller

Paige Miller

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

Looking at this output, i notice a line for total, one for the one-way factor and one for the error. The total variance is that obtained from a null model (no effects). The error variance is the residual error after fitting the model, and the attributed variance component for the one-way factor is the difference between those two. Now comes the tricky part to think about, and it comes from the usual definition of variance component - the variance that is attributable to some random effect. Now if you assume that SERINDEX is a random effect (and thus that this is a simplified nested model), then that value in the R output is then a random variance component.

But in PROC ANOVA, SERINDEX would be fit as a fixed, non-nested effect. Perhaps PROC NESTED would give you what you want. Without the dataset it is hard to tell.

SteveDenham

**SAS Innovate 2025** is scheduled for May 6-9 in Orlando, FL. Sign up to be **first to learn** about the agenda and registration!

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.