I first would like to thank everyone for posting and collaborating to keep this community active, as I have received a lot of help in my analysis browsing these pages.
Brief overview of my research and analysis: I am using distance sampling to estimate the abundance Paddlefish counted on side scan sonar images. We find that the pelagic nature of Paddlefish causes the detection probability of these creatures on sonar to decrease as distance from the boat increases, and distsamp is showing promise in determining the abundance of these animals in this way.
My problem: I hypothesize that the depth of the water affects the sonar image quality in the extremely deep parts of the lakes we are surveying (>15m) and subsequently I believe that the distortion of the sonar image may decrease our ability to detect Paddlefish in these areas. In order to better understand this, I am attempting to fit models where the (mean_depth) of each transect is used as a detection covariate and/or an abundance covariate (in the case Paddlefish distribution is affected by depth). What I have found is that all four keyfun fit when Mean_depth is an abundance covariate, however I receive the error "Error in .local(x, ...) : This method only works when there are no detection covars" when trying to fit mean_depth as a detection covariate using exp, halfnormal, and hazard key functions. Has anyone encountered this issue/ know where I am going wrong? I apologize if there is a simple reason why this is not working, as I am a novice user and not very good at math. Below is an excerpt of some of my models.
exp1<-distsamp(~1~1, umf, keyfun="exp", output="density",unitsOut="ha", se=TRUE)
halfnorm1<-distsamp(~1~1, umf, keyfun="halfnorm", output="density",unitsOut="ha", se=TRUE)
hazard1<-distsamp(~1~1, umf, keyfun="hazard", output="density",unitsOut="ha", se=TRUE)
uniform1<-distsamp(~1~1, umf, keyfun="uniform", output="density",unitsOut="ha", se=TRUE)
exp_wDepth4abund<-distsamp(~1~Mean_Depth_m, umf, keyfun="exp", output="density",unitsOut="ha", se=TRUE)
halfnorm_wDepth4abund<-distsamp(~1~Mean_Depth_m, umf, keyfun="halfnorm", output="density",unitsOut="ha", se=TRUE)
hazard_wDepth4abund<-distsamp(~1~Mean_Depth_m, umf, keyfun="hazard", output="density",unitsOut="ha", se=TRUE)
uniform_wDepth4abund<-distsamp(~1~Mean_Depth_m, umf, keyfun="uniform", output="density",unitsOut="ha", se=TRUE)
exp_wDepth4det<-distsamp(~Mean_Depth_m~1, umf, keyfun="exp", output="density",unitsOut="ha", se=TRUE)
halfnorm_wDepth4det<-distsamp(~Mean_Depth_m~1, umf, keyfun="halfnorm", output="density",unitsOut="ha", se=TRUE)
hazard_wDepth4det<-distsamp(~Mean_Depth_m~1, umf, keyfun="hazard", output="density",unitsOut="ha", se=TRUE)
uniform_wDepth4det<-distsamp(~Mean_Depth_m~1, umf, keyfun="uniform", output="density",unitsOut="ha", se=TRUE)