Hi there I am trying to compute Type III SS plus model selection and find that an error pops up when I'm trying to use the drop1() function with a model output using Anova(). I am looking at effects of four factors and their interactions (with unbalanced sample sizes across some factor groups), on a continuous variable. I get an error that reads: "Error in terms.default(object) : no terms component not attribute". I also can't compute an AIC for the model outputs. I am wondering if there is something I need to do to my data or if there is some limitation to the analysis I am trying to do.
Omg omg! Search on "type III as R good or bad" or similar for why you should of should not be doing this. As for your specific question, I doubt that you'll get a useful reply until you post the code that elicited the error. Maybe not even then if it is due to estimability/overfitting of your data. And that you cannot obtain an aic seems unsurprising, as you said you cannot fit the model and so cannot get a likelihood and so cannot possibly obtain a penalized likelihood. Or do I misunderstand? If so, please ignore. If not, my best advice would be to ignore all this SS business altogether and talk with a local statistician about how or if your data might answer scientific questions of interest. Cheers, Bert On Jul 16, 2016 6:16 PM, "Pamela Wong" <pamela.wong at mail.utoronto.ca> wrote:> Hi there > > I am trying to compute Type III SS plus model selection and find that an > error pops up when I'm trying to use the drop1() function with a model > output using Anova(). I am looking at effects of four factors and their > interactions (with unbalanced sample sizes across some factor groups), on a > continuous variable. > > I get an error that reads: "Error in terms.default(object) : no terms > component not attribute". I also can't compute an AIC for the model outputs. > > I am wondering if there is something I need to do to my data or if there > is some limitation to the analysis I am trying to do. > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. >[[alternative HTML version deleted]]
Dear Pamela, It's very hard to tell from your message what you did, but I'm guessing that you passed the object produced by Anova() to drop1(). If this is in fact what you did, it makes no sense, because Anova() doesn't produce a linear-model object but rather takes such an object as its argument. I hope this helps, John -------------------------------------- John Fox, Professor McMaster University Hamilton, Ontario, Canada Web: socserv.mcmaster.ca/jfox> -----Original Message----- > From: R-help [mailto:r-help-bounces at r-project.org] On Behalf Of Pamela > Wong > Sent: Saturday, July 16, 2016 1:12 AM > To: r-help at r-project.org > Subject: [R] Troubleshooting Type III SS and drop1() > > Hi there > > I am trying to compute Type III SS plus model selection and find that an > error pops up when I'm trying to use the drop1() function with a model > output using Anova(). I am looking at effects of four factors and their > interactions (with unbalanced sample sizes across some factor groups), > on a continuous variable. > > I get an error that reads: "Error in terms.default(object) : no terms > component not attribute". I also can't compute an AIC for the model > outputs. > > I am wondering if there is something I need to do to my data or if there > is some limitation to the analysis I am trying to do. > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting- > guide.html > and provide commented, minimal, self-contained, reproducible code.