refine | R Documentation |
This is a generic function with currently methods for SLik
, SLik_j
and SLikp
objects (as produced by MSL
). Depending on the value of its newsimuls
argument, and on whether the function used to generate empirical distributions can be called by R, it (1) defines new parameters points and/or (2) infers their summary likelihood or tail probabilities for each parameter point independently, adds the inferred values results as input for refined inference of likelihood or P-value response surface, and provides new point estimates and confidence intervals.
## S3 method for class 'SLik' refine(object, method=NULL, ...) ## Default S3 method: refine(object, surfaceData, Simulate = attr(surfaceData,"Simulate"), maxit = 1, n = NULL, useEI = list(max=TRUE,profileCI=TRUE,rawCI=FALSE), newsimuls = NULL, trypoints=NULL, useCI = TRUE, level = 0.95, verbose = list(most=interactive(),final=NULL,movie=FALSE,proj=FALSE), precision = Infusion.getOption("precision"), nb_cores = NULL, packages=attr(object$logLs,"packages"), env=attr(object$logLs,"env"), method, eval_RMSEs=TRUE, update_projectors = FALSE, cluster_args=list(), cl_seed=.update_seed(object), ...)
object |
an |
surfaceData |
A data.frame with attributes, usually taken from the |
Simulate |
Character string: name of the function used to simulate samples. The only meaningful non-default value is |
maxit |
Maximum number of iterative refinements (see also |
n |
A number of parameter points (excluding replicates and confidence interval points), whose likelihood should be computed
(see |
useEI |
Cf this argument in |
newsimuls |
For the For other methods, a |
trypoints |
A data frame of parameters on which the simulation function |
useCI |
whether to include parameter points near the inferred confidence interval points in the set of points which likelihood should be computed |
level |
Intended coverage of confidence intervals |
verbose |
A list as shown by the default, or simply a vector of booleans. |
precision |
Requested local precision of surface estimation, in terms of prediction standard errors (RMSEs) of both the maximum summary log-likelihood and the likelihood ratio at any CI bound available. Iterations will stop when either |
nb_cores |
Shortcut for |
cluster_args |
A list of arguments for |
packages |
NULL or a list with possible elements |
env |
An environment, passed as the |
method |
(A vector of) suggested method(s) for estimation of smoothing parameters (see |
eval_RMSEs |
passed to |
update_projectors |
Boolean; whether to update the projectors at each iteration. |
cl_seed |
NULL or integer, passed to |
... |
further arguments passed to or from other methods. |
New parameter points are sampled as follows: the algorithm aims to sample uniformly the space of parameters contained in the confidence regions defined by the level
argument, and to surround it by a region sampled proportionally to likelihood. In each iteration the algorithm aims to add as many points (say n) as computed in the first iteration, so that after k iterations of refine
, there are n * (k+1) points in the simulation table. However, when not enough points satisfy certain criteria, only n/5 points may be added in an iteration, this being compensated in further iterations. For example, if n=600, the table may include only 720 points after the first refine, but 1800 after the second.
independent control of parallel computation for sample simulation and RMSE computations is possible:
control_args=list(RMSE=list(spec=<number of 'children'>))
can be used to force parallel computation of RMSEs;
control_args=list(spec=<.>, <other makeCluster arguments>))
would instead apply the same arguments to both reference table and RMSE computation, overcoming the default effect of nb_cores
; finally
control_args=list(reftable=list(<makeCluster arguments>),RMSEs=list(<makeCluster arguments>))
allows full independent control of parallelisation for the two computations.
refine
returns an updated SLik
or SLik_j
object.
See workflow examples in (by order of decreasing relevance) example_reftable
, example_raw_proj
and example_raw
.
## see Note for links to examples.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.