Skip to content

Commit f4a7197

Browse files
committed
rename compute_ht_metrics() to calc_ht_metrics()
1 parent 5490f66 commit f4a7197

5 files changed

Lines changed: 15 additions & 15 deletions

File tree

NAMESPACE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
export(.get_fia_plot_geom)
44
export(.get_tree_list_xy)
55
export(DEFAULT_TREE_COLUMNS)
6-
export(compute_ht_metrics)
6+
export(calc_ht_metrics)
77
export(create_fia_owin)
88
export(create_fia_ppp)
99
export(load_tree_data)
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
#' Compute plot-level stand height metrics
1+
#' Calculate plot-level stand height metrics
22
#'
3-
#' `compute_ht_metrics()` computes several stand height metrics for a given FIA
3+
#' `calc_ht_metrics()` computes several stand height metrics for a given FIA
44
#' plot, i.e., across the full four-subplot cluster (see Details).
55
#'
66
#' @details
@@ -37,10 +37,10 @@
3737
#' in Details.
3838
#'
3939
#' @examples
40-
#' compute_ht_metrics(plantation)
40+
#' calc_ht_metrics(plantation)
4141
#'
4242
#' @export
43-
compute_ht_metrics <- function(tree_list, digits = 1) {
43+
calc_ht_metrics <- function(tree_list, digits = 1) {
4444

4545
if (missing(tree_list) || is.null(tree_list))
4646
stop("'tree_list' is required", call. = FALSE)

_pkgdown.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ home:
1414
reference:
1515
- title: Functions
1616
- contents:
17-
- compute_ht_metrics
17+
- calc_ht_metrics
1818
- load_tree_data
1919
- overlay_crowns
2020
- plot_crowns
Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
test_that("compute_ht_metrics works", {
1+
test_that("calc_ht_metrics works", {
22
expected <- vector(mode = "list", length = 8)
33
names(expected) <- c("meanTreeHt", "meanTreeHtBAW", "meanTreeHtDom",
44
"meanTreeHtDomBAW", "maxTreeHt", "predomTreeHt",
@@ -11,5 +11,5 @@ test_that("compute_ht_metrics works", {
1111
expected$predomTreeHt <- 50.3
1212
expected$meanSapHt <- 33.5
1313
expected$maxSapHt <- 42
14-
expect_equal(compute_ht_metrics(plantation), expected, tolerance = 0.1)
14+
expect_equal(calc_ht_metrics(plantation), expected, tolerance = 0.1)
1515
})

0 commit comments

Comments
 (0)