evsivar.Rd
Calculate the expected value of sample information for an estimation problem. This computes the expected reduction in variance in some quantity of interest from a study of a certain design that informs the parameters of interest.
evsivar( outputs, inputs, study = NULL, datagen_fn = NULL, pars = NULL, n = 100, method = NULL, likelihood = NULL, analysis_model = NULL, analysis_options = NULL, decision_model = NULL, Q = 30, npreg_method = "gam", nsim = NULL, verbose = TRUE, ... )
outputs | a vector of values for the quantity of interest, sampled from the uncertainty distribution of this quantity that is induced by the uncertainty about the parameters. |
---|---|
inputs | Matrix or data frame of samples from the uncertainty
distribution of the input parameters of the decision model. The number
of columns should equal the number of parameters, and the columns should
be named. This should have the same number of rows as there are samples
in |
study | Name of one of the built-in study types supported by this package for EVSI calculation. If this is supplied, then the columns of Currently supported studies are
Either |
datagen_fn | If the proposed study is not one of the built-in types supported, it can be specified in this argument as an R function to sample predicted data from the study. This function should have the following specification: 1. the function's first argument should be a data frame of parameter simulations, with one row per simulation and one column per parameter. The parameters in this data frame must all be found in 2. the function should return a data frame. 3. the returned data frame should have number of rows equal to the number of parameter simulations in 4. if 5. the function can optionally have more than one argument. If so, these additional arguments should be given default values in the definition of Examples of this are currently in the |
pars | Character vector identifying which columns of For example, if The |
n | Sample size of future study - optional argument to datagen_fn - facilitates calculating EVSI for multiple sample sizes. TODO if we want to design trials with multiple unbalanced arms, we'll need more than one argument. |
method | See |
likelihood | Likelihood function, required (and only required) for the importance sampling method. This should have two arguments as follows: 1. a data frame of predicted data. Columns are defined by the number of outcomes in the data, and names matching the data frame returned by 2. a data frame of parameter values, whose names should all correspond to variables in The function should return a vector whose length matches the number of rows of the parameters data frame given as the second argument. Each element of the vector gives the likelihood of the corresponding set of parameters, given the data in the first argument. Examples of this are currently in Note the definition of the likelihood should agree with the definition of |
analysis_model | Function which fits a Bayesian model to the generated data. Under development (need to decide format, output, JAGS dependencies, etc.). Required for |
analysis_options | List of arguments required by |
decision_model | Function which evaluates the decision-analytic model, given parameter values. Under development - for |
Q | Number of quantiles to use in |
npreg_method | Method to use to calculate the EVPPI, for those methods that require it. This is passed to |
nsim | Number of simulations from the model to use for calculating EVPPI. The first |
verbose | If |
... | Other arguments required by specific methods |
Jackson, Jackson, C., Presanis, A., Conti, S., & De Angelis, D. (2019). Value of information: Sensitivity analysis and research design in Bayesian evidence synthesis. Journal of the American Statistical Association, 114(528), 1436-1449.