On Sep 13, 2012, at 9:00 AM, David Winsemius wrote: > > On Sep 13, 2012, at 5:52 AM, KerryGK wrote: > >> I am using the AICmodavg package and using R version 2.15.1. I need help >> with code that is instead being read as text. >> >> Below is a subset of code... I actually have 12 models, but I am trying to >> get this to work for 2 below right now. >> >> Everything 'appears' to work through the line starting with Modnames. After >> that the code starting with aictab and beyond is recognized as text and not >> code. What am I doing incorrectly with the code? >> >> buco.models<-list ( ) >> buco.models [[1]] <- glm(P.BUCO~faverage+W15CNT, family=binomial(logit), >> data=AmphAIC) >> buco.models [[2]] <- glm(P.BUCO~diam1+W15CNT, family=binomial(logit), >> data=AmphAIC) >> Modnames<-paste (“mod” , 1:length(buco.models), sep=") > ------------------------------------------------------^ > Not at all surprising. The usual response of a programmer faced with code > that goes wrong at a particular point should be to _first_ look for missing > commas or parentheses. In your case it is a missing comma.
Skitt's Law, again. comma != double-quote. > >> aictab(cand.set = buco.models, modnames = Modnames, sort=TRUE)) >> print(aictab(cand.set = buco.models, modnames = Modnames, sort=TRUE) digits >> = 4) >> > -- David Winsemius, MD Alameda, CA, USA ______________________________________________ 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 and provide commented, minimal, self-contained, reproducible code.