Density covariates

questions concerning anlysis/theory using program DENSITY and R package secr. Focus on spatially-explicit analysis.

Density covariates

Postby demarsea » Thu Oct 07, 2021 4:51 pm

Hi Murray,

I've been troubleshooting density covariates analysis for some time and can't seem to get the code to run properly.

I'm doing mark-resight of butterflies, and looking at 3 covariates Canopy, Elevation, and Ceanothus (host plant density), and interactions between canopy+ceanothus and elevation+ceanothus. Trap type is "count".

Code: Select all
base.args <- list(capthist = Ald2019aCH, mask = clippedmask, trace = FALSE, verify=FALSE, method='Nelder-Mead')
 args.0 <- c(base.args, model = D ~ 1)
 args.Dcan <- c(base.args, model = D ~ 'Canopy2')
 args.Delv <- c(base.args, model = D ~ 'Elvpcl_buff3')
 args.Dnjt <- c(base.args, model = D ~ 'Ceanothus2_num')
 args.Dnjtelv <- c(base.args, model = D ~ 'Ceanothus2_num' + 'Elvpcl_buff3')
 args.Dnjtcan <- c(base.args, model = D ~ 'Ceanothus2_num' + 'Canopy2')
arglist <- list(null = args.0, Dcan = args.Dcan, Delv = args.Delv, Dnjt = args.Dnjt, Dnjtelv = args.Dnjtelv, Dnjtcan = args.Dnjtcan)
fits <-

First I attempted without method=Nelder-Mead and then with it. Both had the same outcome:

Error in getmaskpar(!CL, D, data$m, sessnum, details$unmash, attr(data$capthist, :
bad densities in 'secrloglikfn' (try different optimisation method, link, or model?

I'm unclear how to troubleshoot ie "try different optimisation method, link, or model" exactly. Pretty new to R!

Thank you for any assistance.
Posts: 3
Joined: Wed Mar 17, 2021 12:23 pm

Re: Density covariates

Postby murray.efford » Thu Oct 21, 2021 5:37 pm

I have no idea either. Maybe some bad covariates in there? If you still want to pursue this, send me the data offline.
Posts: 645
Joined: Mon Sep 29, 2008 7:11 pm
Location: Dunedin, New Zealand

Return to analysis help

Who is online

Users browsing this forum: No registered users and 1 guest