Point Transects - With Covariates

Intermediate
Author

Trent McDonald

Published

April 8, 2025

Modified

April 24, 2025

Abundance via point-transects distance-sampling (point counts) when detection depends on covariates.

library(Rdistance)
Loading required package: units
udunits database from C:/Users/trent/AppData/Local/R/win-library/4.4/units/share/udunits/udunits2.xml
Rdistance (v4.0.5)
data(thrasherDf)
oneHectare <- units::set_units(1, "ha")
dfuncFit <- thrasherDf |>
  dfuncEstim(dist ~ bare + shrub + groupsize(groupsize)
             , likelihood = "hazrate") |> 
  abundEstim(area = oneHectare
             , ci = NULL)
summary(dfuncFit)
Call: dfuncEstim(data = thrasherDf, dist ~ bare + shrub +
   groupsize(groupsize), likelihood = "hazrate")
Coefficients:
             Estimate   SE  z   p(>|z|)
(Intercept)  4.2534879  NA  NA  NA     
bare         0.8884159  NA  NA  NA     
shrub        0.4584574  NA  NA  NA     
k            1.0061209  NA  NA  NA     

Convergence: VARIANCE FAILURE (singular variance-covariance matrix)
Function: HAZRATE  
Strip: 0 [m] to 265 [m] 
Average effective detection radius (EDR): 265 [m] (range 265 [m] to 265 [m]) 
Average probability of detection: 1 (range 1 to 1)
Scaling: g(0 [m]) = 1
Log likelihood: -1076.888 
AICc: 2161.988

     Surveyed Units: 120 
   Individuals seen: 196 in 193 groups 
 Average group size: 1.015544 
   Group size range: 1 to 2 
Density in sampled area: 7.403434e-06 [1/m^2]
Abundance in 10000 [m^2] study area: 0.07403434
plot(dfuncFit
     , newdata = data.frame(bare = c(30, 35, 40)
                            , shrub = 20)
     , lty = 1)