[R] GLM and LM singularities

Michael Dewey info at aghmed.fsnet.co.uk
Mon Nov 27 12:43:03 CET 2006


At 23:12 26/11/2006, Tim Sippel wrote:
>Hi-
>
>I'm wrestling with some of my data apparently not being called into a GLM or
>an LM.  I'm looking at factors affecting fish annual catch rates (ie. CPUE)
>over 30 years.  Two of the factors I'm using are sea surface temperature and
>sea surface temperature anomaly.  A small sample of my data is below:
>
>

I could not make much sense of the dataset and your output is 
incomplete (what happened to Year?) but usually the message you 
received means that one of your predictors is a linear combination of 
some of the others.



>CPUE
>
>Year
>
>Vessel_ID
>
>Base_Port
>
>Boat_Lgth
>
>Planing
>
>SST
>
>Anomaly
>
>
>0.127
>
>1976
>
>2
>
>BOI
>
>40
>
>Planing
>
>19.4
>
>-0.308
>
>
>0.059
>
>1976
>
>30
>
>BOI
>
>40
>
>Displacement
>
>19.4
>
>-0.308
>
>
>0.033333
>
>1977
>
>46
>
>BOI
>
>45
>
>Displacement
>
>18.5
>
>-1.008
>
>
>0.169231
>
>1977
>
>2
>
>BOI
>
>40
>
>Planing
>
>18.5
>
>-1.008
>
>
>0.044118
>
>1977
>
>19
>
>BOI
>
>34
>
>Planing
>
>18.5
>
>-1.008
>
>
>0.114286
>
>1977
>
>29
>
>WHANGAROA
>
>42
>
>Displacement
>
>18.5
>
>-1.008
>
>
>
>Have defined Year, Vessel_ID, Base_Port, Boat_Lgth, Planing as factors, and
>CPUE, SST, Anomaly are continuous variables.
>
>
>
>The formula I'm calling is: glm(formula = log(CPUE) ~ Year + Vessel_ID +
>SST, data = marlin).  A summary of the glm includes the following output:
>
>
>
>Coefficients: (1 not defined because of singularities)
>
>             Estimate Std. Error t value Pr(>|t|)
>
>Vessel_ID80 -0.54093    0.23380  -2.314 0.021373 *
>
>Vessel_ID83 -0.36499    0.20844  -1.751 0.080977 .
>
>Vessel_ID84 -0.23386    0.19098  -1.225 0.221718
>
>SST               NA         NA      NA       NA
>
>
>
>Can someone explain the output "Coefficients: (1 not defined because of
>singularities)"? What does this mean?  I'm guessing that something to do
>with my SST data is causing a "singularity" but I don't know where to go
>from there?  Have inspected various R discussions on this, but I haven't
>found the information I need.
>
>
>
>Many thanks,
>
>
>
>Tim Sippel (MSc)
>
>School of Biological Sciences
>
>Auckland University
>
>Private Bag 92019
>
>Auckland 1020
>
>New Zealand
>
>+64-9-373-7599 ext. 84589 (work)
>
>+64-9-373-7668 (Fax)
>
>+64-21-593-001 (mobile)
>
>
>
>
>         [[alternative HTML version deleted]]

Michael Dewey
http://www.aghmed.fsnet.co.uk



More information about the R-help mailing list