Allow the user to set and examine a variety of options which affect operations of the Infusion package. However, typically these should not be modified, and if they are, not more than once in a data analysis.
Infusion.options(...)Infusion.getOption(x)
For Infusion.getOption
, the current value set for option x
, or
NULL
if the option is unset.
For Infusion.options()
, a list of all set options. For
Infusion.options(name)
, a list of length one containing the set value,
or NULL
if it is unset. For uses setting one or more options,
a list with the previous values of the options changed (returned
invisibly).
a character string holding an option name.
A named value or a list of named values. The following values, with their defaults,
are used in Infusion
:
mixturing
character string: package or function to be used for mixture modelling. Recognized packages are "Rmixmod"
(the default) and "mclust"
;
train_cP_size
:Expression for train_cP_size
argument of project.character
.
trainingsize
:Expression for trainingsize
argument of project.character
.
projKnotNbr = 1000
:default value of trainingsize
argument of project.character
for REML (as implied by default expression for trainingsize
).
logLname = "logL"
:default value of logLname
argument of infer_logLs
. The name given to the inferred log likelihoods in all analyses.
LRthreshold= - qchisq(0.999,df=1)/2
:A value used internally by sample_volume
to sample points
in the upper region of the likelihood surface, as defined by the given likelihood ratio threshold.
precision = 0.1
:default value of precision
argument of refine
. Targets RMSE of log L and log LR estimates.
nRealizations=1000
:default value of nRealizations
argument of add_simulation
. Number of realizations for each empirical distribution.
mixmodGaussianModel="Gaussian_pk_Lk_Dk_A_Dk"
:default models used in clustering by Rmixmod
. Run Rmixmod::mixmodGaussianModel()
for a list of possible models, and see the statistical documentation (Mixmod Team 2016) for explanations about them.
seq_nbCluster= function(projdata, nr=nrow(projdata)) {seq(ceiling(nr^0.3))}
:function to control the value of nbCluster
used in clustering by Rmixmod
(see Details for discussion of this default).
maxnbCluster = function(projdata) {...}
:function to control the maximum number of clusters (see Details).
example_maxtime=2.5
:Used in the documentation to control whether the longer examples should be run. The approximate running time of given examples (or some very rough approximation for it) on one author's laptop is compared to this value.
nb_cores
Number of cores for parallel computations (see Details for implementation of these).
gof_nstats_fn
See goftest
.
and possibly other undocumented values for development purposes.
The set of the number of clusters tried (nbCluster
argument in Rmixmod
) is controlled by two options: seq_nbCluster
and maxnbCluster
. The second is used to correct the first, using the dimensions of the projdata
locally used for clustering, which typically differs from the dimensions of the user-level data
(if projections have been applied, in particular). The default upper value of the nbCluster
range is the value recommended in the mixmod
statistical documentation (Mixmod Team, 2016). But this default may be suitable only for low-dimensional data, hence the need for correcting it bymaxnbCluster
.
Infusion
can perform parallel computations if several cores are available and requested though Infusion.options(nb_cores=.)
. If the doSNOW
back-end is attached (by explicit request from the user), it will be used; otherwise, pbapply
will be used. Both provide progress bars, but doSNOW
may provide more efficient load-balancing. The character shown in the progress bar is 'P'
for parallel via doSNOW
backend, 'p'
for parallel via pbapply
functions, and 's'
for serial via pbapply
functions. In addition, add_simulation
can parallelise at two levels: at an outer level over parameter point, or at an inner level over simulation replicates for each parameter point. The progress bar of the outer computation is shown, but the character shown in the progress bar is 'N'
if the inner computation is parallel via the doSNOW
backend, and 'n'
if it is parallel via pbapply
functions. So, one should see either 'P'
or 'N'
when using doSNOW
.
Mixmod Team (2016). Mixmod Statistical Documentation. Université de Franche-Comté, Besançon, France. Version: February 10, 2016 retrieved from https://www.mixmod.org.
Infusion.options()
Infusion.getOption("LRthreshold")
if (FALSE) {
Infusion.options(LRthreshold=- qchisq(0.99,df=1)/2)
}
Run the code above in your browser using DataLab