[R] error in eval
dcarlson at tamu.edu
Tue Nov 26 15:53:14 CET 2013
And in fact
is included on page 560. You must have left it out of your
example code. Without it, your first example would not have run
David L Carlson
Department of Anthropology
Texas A&M University
College Station, TX 77840-4352
From: r-help-bounces at r-project.org
[mailto:r-help-bounces at r-project.org] On Behalf Of peter
Sent: Tuesday, November 26, 2013 8:01 AM
Cc: r-help help
Subject: Re: [R] error in eval
AFAICT, your code should not be expected to run unless you have
an attach(lizards) prior to the glm() call. Either that or you
need data=lizards in the call itself.
On 26 Nov 2013, at 12:43 , philthe1st
<philip.brown at bristol.ac.uk> wrote:
> Hi there, I am learning to use and understand R but have come
up against a
> problem. I'm sure it is a pretty simple thing, but I can't
find a solution.
> I wonder if anyone could help?
> I have been using the "The R Book" by Crawley and working
through some of
> the examples before trying to apply them to my data.
> Yesterday I tried to following from page 560:
> n sun height perch time species
> 1 20 Shade High Broad Morning opalinus
> 2 13 Shade Low Broad Morning opalinus
> 3 8 Shade High Narrow Morning opalinus
> 4 6 Shade Low Narrow Morning opalinus
> 5 34 Sun High Broad Morning opalinus
> 6 31 Sun Low Broad Morning opalinus
> The GLM worked and I got the correct results.
> In the mean time I have had a play around with my data in R
> package "pscl". I then then came to back to page 560 to play
> some variables and could not load the glm I needed. This time,
> exact same codes as above I received the message:
> Error in eval(expr, envir, enclos) : object 'n' not found
> Looking at other peoples questions about this problem I have
> "sep" but with no luck. Can anyone help me work out what has
> yesterday and how to get the glm codes working again?
> Thank you in advance for any help/suggestions.
> View this message in context:
> Sent from the R help mailing list archive at Nabble.com.
> R-help at r-project.org mailing list
> PLEASE do read the posting guide
> and provide commented, minimal, self-contained, reproducible
Peter Dalgaard, Professor
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Email: pd.mes at cbs.dk Priv: PDalgd at gmail.com
R-help at r-project.org mailing list
PLEASE do read the posting guide
and provide commented, minimal, self-contained, reproducible
More information about the R-help