Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
Reference #157
  • Loading branch information
LHMarshall committed Dec 22, 2023
1 parent 293ddcf commit 896804c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
5 changes: 4 additions & 1 deletion R/bootdht.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@
#'
#' @param model a model fitted by [`ds`] or a list of models
#' @param flatfile Data provided in the flatfile format. See [`flatfile`] for
#' details.
#' details. Please note, it is a current limitation of bootdht that all
#' Sample.Label identifiers must be unique across all strata, i.e.transect
#' ids must not be re-used from one strata to another. An easy way to achieve
#' this is to paste together the stratum names and transect ids.
#' @param convert_units conversion between units for abundance estimation, see
#' "Units", below. (Defaults to 1, implying all of the units are "correct"
#' already.) This takes precedence over any unit conversion stored in `model`.
Expand Down
5 changes: 4 additions & 1 deletion man/bootdht.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions tests/testthat/test_bootdht.R
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ minke$distend <- vals[minke$bin+1]
# remove exact distances
minke$distance <- NULL

test_that("Issue #158 is fixed (stratum names > 'Total' bug)", {
test_that("Issue #147 is fixed (bootdht with distbegin/distend)", {

skip_on_cran()
mod1 <- ds(minke)
Expand All @@ -181,8 +181,7 @@ dat$Region.Label <- c(rep("StrataA", 30), rep("StrataB", 30))
dat$distance <- abs(rnorm(nrow(dat), 0, 25))
dat$size <- rpois(nrow(dat), 20)
dat$ref.object <- dat$object

test_that("Error raised when sampler ID not unique", {
test_that("Error raised when sampler ID not unique (Issue #157)", {

set.seed(123)
expect_error(bootdht_resample_data(dat, c("Sample.Label")),
Expand Down

0 comments on commit 896804c

Please sign in to comment.