0

Question: How can I get the response variable "Camp" to show all 4 camps/locations into the output. On the below output it shows CampKM20, CampZNS, CampHormiguero, but the 4th camp "Dos Naciones" is missing. How can I get the output to include this?

Hi I'm new to R and I'm having trouble with the outcomes. A large datafile from excel has been uploaded in to R. I've used the below code to find out what habitat variables are important/significant to herpetofauna abundances:

> AllHerps <- lmer(Abun_All_Herps ~ Total_Saplings *
> Total_Understorey_Vegetation * Tree_Species_Richness * Mean_DBH *
> Total_Basal_Area * Mean_Canopy_Openess * Mean_Leaf_Litter_Depth +
> Aguada_Distance_Category * Camp * (1|Year),
>                   data=DataAbunAllHerps)

When obtaining the summary, Summary(AllHerps), I get the following output

> Fixed effects:
>                                    Estimate   Std. Error   df     t value    Pr(>|t|)
> 
> (Intercept)                      2.233e+00  2.309e-01  3.361e+01   9.668     3.10e-11 ***                            
> Total_Saplings                   9.417e-04  1.166e-01  2.843e+02   0.008     0.993561    
> Total_Understorey_Vegetation     1.525e-01  1.106e-01  3.154e+02   1.379     0.168851 
> CampHormiguero                  -5.732e-01  2.395e-01  3.273e+02  -2.393     0.017255 *
> CampKM20                        -6.844e-01  2.762e-01  3.146e+02  -2.478     0.013738 *   
> CampZNS                         -7.648e-01  2.616e-01  3.290e+02  -2.924     0.003700 **  
> And more outputs follow after here with interactions, but as mentioned I'm missing the Dos Naciones Camp from the output

And more outputs follow after here with interactions, but as mentioned I'm missing the Dos Naciones Camp from the output. Any help would be great, thank you

Progman
  • 16,827
  • 6
  • 33
  • 48
Hefin
  • 1
  • 1
  • Generally the first level of a factor is treated as the reference level. So your intercept value is for Dos Naciones, and then the other Camp coeffiecients are the differences between those camps and Dos Naciones. – Gregor Thomas Oct 07 '22 at 19:05
  • with categorical variables in R regression output, one is chosen as the referent group. That is all other levels of that variable are compared to that group. Since it is the comparator there is no coefficient for it and does not have output from the regression. – Mike Oct 07 '22 at 19:05

0 Answers0