rbchan / unmarked

R package for hierarchical models in ecological research
https://rbchan.github.io/unmarked/
36 stars 25 forks source link

Copy lme4 code into package, instead of importing it #253

Open kenkellner opened 1 year ago

kenkellner commented 1 year ago

We only use a handful of functions from lme4 for processing random effects (findbars, nobars, mkReTrms). It looks like these functions have not been changed in 5+ years. Given that we don't actually use lme4 to fit models I think it could make more sense to copy these functions to unmarked and remove the dependency on lme4, which would simplify things for both packages. I think the following requirements apply:

  1. Make sure the licenses are compatible (both are GPL-3 so that's fine)
  2. Copy lme4 code to a new file, say lme4Code.R which has comments clearly indicating its origin
  3. Add appropriate authorship. In this case I think we would add "Douglas Bates and lme4 authors (lme4Code.R)" to the package authors.
kenkellner commented 1 year ago

@rbchan What do you think? I'm going to have to do a new submission soon to fix this new CRAN error, so I may make this change for that submission.

rbchan commented 1 year ago

Sounds good to me. You might ask Douglas Bates and the lme4 authors if they want to be listed as unmarked authors.