Description Usage Arguments Details Value References Examples
View source: R/bayesian_tests.R
This function implements a Bayesian hierarchical test. The performance of one baseline algorithm on multiple data set is compared to either one or multiple algorithms.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | b_hierarchical_test(
df,
baseline,
algorithm = NULL,
measure = NULL,
rho = 0.1,
compare = NULL,
std.upper = 1000,
d0.lower = NULL,
d0.upper = NULL,
prob = 0.95,
alpha.lower = 0.5,
alpha.upper = 5,
beta.lower = 0.05,
beta.upper = 0.15,
rope = c(-0.01, 0.01),
nsim = 2000,
parallel = TRUE,
stan.output.file = NULL,
nchains = 8,
seed = as.numeric(Sys.time()),
adapt_delta = 0.8,
max_treedepth = 10
)
|
df |
('list') |
baseline |
('character') |
algorithm |
('character') |
measure |
('character') |
rho |
('double') |
compare |
('character') |
std.upper |
('double') |
d0.lower |
('any') |
d0.upper |
('any') |
prob |
('double') |
alpha.lower |
('double') |
alpha.upper |
('double') |
beta.lower |
('double') |
beta.upper |
('double') |
rope |
('double') |
nsim |
('double') |
parallel |
('logical') |
stan.output.file |
('character') |
nchains |
('double') |
seed |
('double') |
adapt_delta |
('double') |
max_treedepth |
('double') |
The test has first been implemented in scmamp. Note that if no measure column is defined per default the first column defined as measure_* in the data frame is used. The default of rho is 0.1.
('list')
A list containing the following components:
measure
('character')
A string with the name of the
measure column.
method
('character')
A string with the name of the
method.
baseline
('character')
A string with the name of the
first algorithm. Value in 'algorithm' column.
data_frame
('list')
A list containing the following
components:
algorithm
('character')
Second algorithm. Value in
'algorithm' column. If not defined, the baseline is tested against
all algorithms in the data frame.
left
('double')
Left probability.
rope
('double')
Rope probability.
right
('double')
Right probability.
probabilities
('character')
Decisions based on posterior
probabilities and threshold probability.
https://github.com/b0rxa/scmamp
1 2 3 4 5 6 | ## Not run:
results <- b_hierarchical_test(df= test_benchmark_small,
baseline = "algo_1", algorithm = "algo_3", rho=0.1,
rope=c(-0.01, 0.01))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.