Moumita Das
2009-Aug-28 12:08 UTC
[R] How to generate mean anova value row in anova table, instead of individual value for each predictor
Hi All , Can anybody tell me if there's any way to get the summarized anova values.Now i will explain what i mean , when i say "*summarized*". Below you can see the anova table of recmeanC1 with rest* all* i.e from recmeanC2 to i15(predictors),as shown in table. Df Sum Squares Mean Square F value Significance [Pr(>F)] recmeanC2 1 89.272 89.272 1.50E+34 < 2e-16 *** recmeanC3 1 9.965 9.965 1.68E+33 < 2e-16 *** recmeanC4 1 2.61 2.61 4.40E+32 < 2e-16 *** i1 1 25.341 25.341 4.27E+33 < 2e-16 *** i2 1 0.118 0.118 1.98E+31 < 2e-16 *** i3 1 0.022 0.022 3.65E+30 < 2e-16 *** i4 1 0.164 0.164 2.75E+31 < 2e-16 *** i5 1 15.639 15.639 2.63E+33 < 2e-16 *** i6 1 1.64E-34 1.64E-34 2.76E-02 0.86812 i7 1 1.72E-33 1.72E-33 2.89E-01 0.59112 i8 1 9.29E-34 9.29E-34 1.57E-01 0.69273 i9 1 6.38E-33 6.38E-33 1.07E+00 0.30092 i10 1 1.02E-32 1.02E-32 1.71E+00 0.19166 i12 1 2.25E-33 2.25E-33 3.80E-01 0.53831 i13 1 2.13E-32 2.13E-32 3.5885e+00 0.53831 0.53831 Regression 15 1.43E+02 9.54E+00 1.61E+33 < 2.2e-16 Residuals 276 1.64E-30 5.94E-33 Total 291 1.43E+02 Instead of the values in the rows from reacmeanC1 to i15...what i want is a summarized value ,what the row named "*Regression*" shows.I do not get anything like the row "Regression".I copied that to show that SPSS has way to generate that.though "Residuals" row is generated in R just like SPSS. I know the how to calculate a single summarized Df,Sum Sq,Mean Sq,F value,Pr(>F) with these formulae:--- *That is instead of all the 15 rows from reacmeanC1 to i15 i want row "Regresssion"* Df Sum Sq Mean Sq F value Regression Calculations sum of all the above dfs sum of all the above Sum of Squares Sum of Squares/df Mean Square due to Regression/Mean Square due to Residuals But isn't there any function in R to get what i explained above in a much easier way? -- Thanks in advance Moumita [[alternative HTML version deleted]]
milton ruser
2009-Aug-28 14:53 UTC
[R] How to generate mean anova value row in anova table, instead of individual value for each predictor
Hi Moumita, Could you send a "minimum reproducible code" as suggested on posting guide?! bests milton On Fri, Aug 28, 2009 at 8:08 AM, Moumita Das <das.moumita.online@gmail.com>wrote:> Hi All , > Can anybody tell me if there's any way to get the summarized anova > values.Now i will explain what i mean , when i say "*summarized*". > > Below you can see the anova table of recmeanC1 with rest* all* i.e from > recmeanC2 to i15(predictors),as shown in table. > > > > > > > > > > > > Df Sum Squares Mean Square F value Significance [Pr(>F)] > recmeanC2 1 89.272 89.272 1.50E+34 < 2e-16 *** > recmeanC3 1 9.965 9.965 1.68E+33 < 2e-16 *** > recmeanC4 1 2.61 2.61 4.40E+32 < 2e-16 *** > i1 1 25.341 25.341 4.27E+33 < 2e-16 *** > i2 1 0.118 0.118 1.98E+31 < 2e-16 *** > i3 1 0.022 0.022 3.65E+30 < 2e-16 *** > i4 1 0.164 0.164 2.75E+31 < 2e-16 *** > i5 1 15.639 15.639 2.63E+33 < 2e-16 *** > i6 1 1.64E-34 1.64E-34 2.76E-02 0.86812 > i7 1 1.72E-33 1.72E-33 2.89E-01 0.59112 > i8 1 9.29E-34 9.29E-34 1.57E-01 0.69273 > i9 1 6.38E-33 6.38E-33 1.07E+00 0.30092 > i10 1 1.02E-32 1.02E-32 1.71E+00 0.19166 > i12 1 2.25E-33 2.25E-33 3.80E-01 0.53831 > i13 1 2.13E-32 2.13E-32 3.5885e+00 0.53831 0.53831 > Regression 15 1.43E+02 9.54E+00 1.61E+33 < 2.2e-16 > Residuals 276 1.64E-30 5.94E-33 > Total 291 1.43E+02 > > Instead of the values in the rows from reacmeanC1 to i15...what i want is a > summarized value ,what the row named "*Regression*" shows.I do not get > anything like the row "Regression".I copied that to show that SPSS has way > to generate that.though "Residuals" row is generated in R just like SPSS. > > I know the how to calculate a single summarized Df,Sum Sq,Mean Sq,F > value,Pr(>F) with these formulae:--- > *That is instead of all the 15 rows from reacmeanC1 to i15 i want row > "Regresssion"* > > > Df Sum Sq Mean > Sq F value > > > > > > Regression Calculations sum of all the above dfs sum of all the above Sum > of Squares Sum of Squares/df Mean Square due to Regression/Mean Square due > to Residuals > > > > But isn't there any function in R to get what i explained above in a much > easier way? > > -- > Thanks in advance > Moumita > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html<http://www.r-project.org/posting-guide.html> > and provide commented, minimal, self-contained, reproducible code. >[[alternative HTML version deleted]]