New release of Distance for Windows; update on recent releases of R packages

76 views
Skip to first unread message

Len Thomas

unread,
Aug 26, 2022, 10:34:10 AM8/26/22
to distance-sampling
Dear Distance software users,

I'm pleased to announce that we have today released a new version of
Distance for Windows, version 7.5 release 1. We have also recently
released updates of many of our R packages on CRAN (the "Comprehensive R
Archive Network" - the place most people download R packages from). I
summarize the main changes below, with a bit of background, and give a
full list at the bottom of this message.

The main place to find information about our Distance software, and get
the new version of Distance for Windows, remains
http://distancesampling.org/

With best wishes to all, Len

- Distance for Windows
- for the analysis engines that use R (MRDS, DSM, MA and
simulations), Distance for Windows is now compatible with the latest
versions of R (4.2.0 and later), because we have switched to calling the
64-bit version of R which is all that is shipped with newer R versions.
The recommended version of R with this release is 4.2.1.
- the simulation engine has been switched to use the dsims package
(the DSsim package has now been retired). Please report any issues you
encounter with the switch. Also note that the ability to run global
simulations with stratified designs is not currently available, we will
make this option available again in the next release. We plan to
rectify this with a second release of Distance 7.5 in the next few months.
- there is a new sample project using the MRDS engine for removal
method distance sampling
- the engines that use R are now compatible with the latest versions
of the mrds and dsm packages (which have had small syntax changes, see
below)
- We have deprecated the moving block bootstrap for variance
estimation in the DSM engine and will remove it in future releases.
(See help page "Variance Estimation via Moving Block Bootstrap" for more
on this.)
- other minor fixes (full list at bottom of email)

R packages:

- mrds 2.2.7 and Distance 1.0.6
- starting values for the likelihood maximization have been changed
from using random values to fixed ones when using monotonicity
constraints, so as to guarantee getting the same result with every run.
The previous behaviour can be brought back if required (set
control$mono.random.start = TRUE). Starting values can also be set
manually if required. Please let us know if this change causes any
issues for you!
- warning and error messages from the likelihood maximization routine
solnp/gosolnp are now not displayed by default, as users found them
difficult to interpret -- they can be seen by setting showit>0
- improvements to robustness of the maximum likelihood routine have
been made by scaling covariates differently from previously
- Fix to reporting of encouter rate and its variance in stratified
analyses. There will be a follow-up post about this in a few days.
- Distance package - fix for detection function variance estimation
-- there will be a follow-up post about this in a few days
- other minor fixes (full list at bottom of email)

- dsm 2.3.3
- to improve consistency of function calls within this package, some
functions and function arguments have changed from having a . to
separate words to having an _. Full list as follows:
- dsm.var.prop -> dsm_var_prop
- dsm.var.gam -> dsm_var_gam
- dsm.var.movblk -> dsm_var_movblk
- dsm.cor -> dsm_cor
- rqgam.check -> rqgam_check
- vis.concurvity -> vis_concurvity
- dsm_varprop
- var_type -> var.type

- dsims
- As noted in a previous email to the list, dsims 1.0.0 has been
released
- The version shipped with Distance for Windows is dsims 1.0.1, which
is available on GitHub (https://github.com/DistanceDevelopment/dsims/).
dims 1.0.1 has various updates for compatibility with Distance for
Windows and a partial fix for using grouped strata for abundance /
density estimation (see NEWS
https://github.com/DistanceDevelopment/dsims/blob/master/NEWS for
further details)

- DSSim
- Our previous simulation package DSSim has been removed from CRAN as
we now recommend all users use dsims
- It is available on github if needed, at
https://github.com/DistanceDevelopment/DSsim

- dssd
- A minor update, version 0.3.4, is on github (not yet on CRAN) -
updates for compatibility with Distance for Windows (see NEWS
https://github.com/DistanceDevelopment/dssd/blob/master/NEWS for further
details)


Full list of updates to R packages is below. (These come from the NEWS
files for each package release.)

In cases there there is a (#number), this refers to an issue on github
that was raised for that package. For example in the Distance package
(#116), the corresponding issue can be found at
https://github.com/DistanceDevelopment/Distance/issues/116

mrds 2.2.7
----------

* Fix bug in check for # parameters < # data. Thanks to Anne Provencher
St-Pierre.
* No longer display errors caused by solnp/gosolnp when doing
constrained optimisation, these can be seen when showit>0 if necessary.
* EXPERIMENTAL change to use fixed grid starting values when using
monotonicity constraints, set control$mono.random.start=TRUE to get old
behaviour.
* Scale covariates absolutely rather than relatively during optimisation.
* Expected.S element of dht return now a data.frame not a list
* Fix total encounter rate and its variance in stratified analysis

Reminder of changes from mrds 2.2.6
----------

(see particularly the syntax changes in the 5th * down this list!)

* Individuals summary table for dht now includes k (number of transects)
* Add effective detection radius (EDR) and its uncertainty to summary output
* Change default rounding of chi-squared test tables. This can be
customized using print(ddf.gof(...), digits=?) for e.g., printing with
knitr::kable
* New detection function: two-part normal ("tpn"), useful for aerial
surveys in mountainous terrain, see Becker EF, Christ AM (2015) A
Unimodal Model for Double Observer Distance Sampling Surveys. PLOS ONE
10(8): e0136403. https://doi.org/10.1371/journal.pone.0136403 and
?"two-part-normal".
* To improve consistency in functions and arguments in the package, some
functions will change from . separation to _. For now both versions
exist but will be removed in mrds 2.2.7.
- add_df_covar_line -> add.df.covar.line
- p_dist_table -> p.dist.table
* Variable strip widths are now supported in dht. Users should supply an
additional column to the sample data.frame ("CoveredArea") giving the
total area covered in the given transect and set
options=list(areas.supplied=TRUE). Thanks to Megan Ferguson for
providing an example, code and feedback.


Distance 1.0.6
----------------------

* Fix bug in auto binning data when using flatfile (#116)
* convert.units in bootdht() was not properly implemented in previous
release, fixed (#122)
* fix bug in detection function variance estimation (#125)
* fix bug in bootstrap where columns needed to be character (thanks to
Nick Wilkinson for finding this)

Reminder of changes from Distance 1.0.5
----------------------

* To improve consistency in functions and arguments in the package, some
functions and arguments have changed from . separation to _. An error is
now thrown when the "old" arguments/functions using . are used. This
error will be removed in Distance 1.0.6.
* create.bins() -> create_bins()
* bootdht():
* convert.units -> convert_units
* ds():
* dht.group -> dht_group
* region.table -> region_table
* sample.table -> sample_table
* obs.table -> obs_table
* convert.units -> convert_units
* er.var -> er_var
* debug.level -> debug_level
* initial.values -> initial_values
* max.adjustments -> max_adjustments
* fix bootdht issue when cluster results were requests (#103)
* improve flatfile documentation (thanks to Maggie Blake for pointing
this out)
* fixed bug in cutpoint calculations in create.bins (#108)
* order argument to ds() is now only used to specify order, to fix a
given number of adjustments use the new argument nadj (see ?ds for more
info)
* fix bug where polynomial adjustments started at the wrong order (2
rather than 4)

dsm 2.3.3
------------------

* To improve consistency in functions in the package, some functions
have changed from . separation to _. For function arguments some
separators have been switched from _ to .. An error is now thrown when
the "old" arguments/functions using . are used. This error will be
removed in dsm 2.3.4.
- dsm.var.prop -> dsm_var_prop
- dsm.var.gam -> dsm_var_gam
- dsm.var.movblk -> dsm_var_movblk
- dsm.cor -> dsm_cor
- rqgam.check -> rqgam_check
- vis.concurvity -> vis_concurvity
- dsm_varprop
- var_type -> var.type

dsims 1.0.0
-------------------

New Features

* Reading transects from file - this functionality is primarily
envisionged for use from within Distance for Windows

Enhancements

* New routine which will generate covariate values from a
zero-truncated Poisson distribution for non integer values.
* There is now no lower limit on the number of detections in
simulations as this was introducing bias. There is now a warning system
in place. Very low numbers of detections may cause issues fitting. There
must be more detections than there are parameters in the model for the
model to have a chance of fitting successfully. Note that distance
sampling good practice recommends minimum of 60-80 detections for
estimating the detection function for line transects and more for points.
* Improved histogram.N.ests function will now plot either a histogram
of estimates of individuals or clusters. It also provides the
use.max.reps argument so that the plot can be consistent with the option
selected for the simulation summary.

Bug Fixes

* Fixed simulations where cluster size was included - there was a
formatting change in mrds output tables.
* Added a check for repeat model definitions.
* Add code to deal with equal model criteria values.
* Fixed bug when no simulation repetitions had been successful
* AICc method fixed
* Warning indexes from parallel runs are now fixed


--
I am a member of the University and College Union and am currently
participating in industrial action to improve UK higher education
staff pension, pay, equality and working conditions. For more
information, please see
https://www.ucu.org.uk/article/11896/Why-were-taking-action.

--
Len Thomas (he/him) len.t...@st-andrews.ac.uk lenthomas.org @len_thom
Centre for Research into Ecological and Environmental Modelling
and School of Mathematics and Statistics
The Observatory, University of St Andrews, Scotland KY16 9LZ
Office: UK+1334-461801 Admin: UK+1334-461842

While I may be sending this email outside of my normal office hours,
I have no expectation to receive a reply outside of yours.

The University of St Andrews is a charity
registered in Scotland, No SC013532.
Reply all
Reply to author
Forward
0 new messages