View source: R/calc_compare2.R
| calc_compare2 | R Documentation |
The calc_compare2 is used for multiple comparisons between different
treatments and create compare2-class. This function is only
applicable to two-factor analysis, see calc_compare for a
single factor version of the function.
calc_compare2(data, .group1, .group2, y, method, ...)
data |
An |
.group1 |
Grouping variables factor 1 (supports only two groups). |
.group2 |
Grouping variables factor 1 (supports only two groups). |
y |
Dependent variable (numeric data). |
method |
The method of difference comparison. Such as |
... |
Other parameters for |
To facilitate code interpretation, it is recommended to use the pipe symbol
|> to connect functions:
nem_compare <- nem |> calc_compare2(.group1 = con_crop, .group2 = season, y = pH, method = TTest2)
An compare2-class object.
Other functions in this R package for data calculations:
calc_beta, calc_beta2, calc_compare,
calc_alpha, calc_nemindex, calc_funguild,
calc_funguild2, calc_mf, calc_mf2,
calc_ter, calc_ter2, calc_ef,
calc_ef2.
nem <- read_nem(tab = easynem_example("nemtab1.csv"),
tax = easynem_example("nemtax1.csv"),
meta = easynem_example("nemmeta1.csv"))
nem_ttest <- nem |>
filter_name(meta, con_crop %in% c("Y2", "Y11")) |>
calc_compare2(.group1 = con_crop, .group2 = season, y = pH, method = TTest2)
nem_ttest
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.