x
based on network distances.
netSI(x,indicator="all", d='HIM', adj.method='cor',
method="montecarlo", k=3, h=20, n.cores, save=FALSE, verbose=TRUE, ...)
all
(default) character string. Indicating all or
one of the four indicators available. This must be on of the strings
"S"
,"SI"
, "Sw"
or "Sd"
.HIM
(default), character string indicating the
distance to be used for the stability computation in case of
indicators S and SI."cor"
(default), optional character string
giving one of the methods available for network inference. For
details see mat2adj
.
"montecarlo"
(default), a string identifying the
cross validation schema to be used for the stability computation.
This must be one of the strings montecarlo
(default),
LOO
for Leave One Out or kCV
for k-fold Cross
Validation.method
is set to
montecarlo
the 1-1/k
samples are taken for the computation.
In case cvlab
is set to loo
it should be set to 1,
otherwise it will be automatically set to 1.
In case cvlab
is set to kCV
h
iteration are
performed, each dividing the data into randomly chosen k
groupsmontecarlo
and kCV
procedure should be repeated(cross validations).NULL
(default), optional numeric value giving
the number of cores to be used for parallel computation. The default
behaviour try to asses the maximum number of available cores and set
a parallel computation using the maximum number of cores - 1 for the
computation.FALSE
(default), logical. Should adjacency matrices
and indicator's raw value from resampling scheme be saved?TRUE
(default), logical. Print all the
information about the computation. If FALSE
messages will be suppressed.save=TRUE
:
save=FALSE
elements call
, ADJlist
, ADJ
,
S_boot
, SI_boot
, Sw_boot
and Sd_boot
will
not be provided. For S
and SI
the mean over the
resampling splits is computed, instead for the element Sw
and
Sd
the range/mean is computed over resamplings.
mat2adj
and network
distance function netdist
.
Parameters passed through ... will be used by the low-level
functions mat2adj
and netdist
.Indicators:
S
: is the global stability indicator. It asses the
pertubations of the network given by the resampling: in particular it
account for the distance between the network inferred using all
samples and the network inferred on a subsampling.
SI
: is the local stability indicator. It provides a
measure of the perturbations between different subsamplings. It
computes the pairwise distances between networks inferred on different subsamplings.
Sw
: is the edge stability indicator. It asses the
stability of the edges inferred in different subsamplings. In case
of a binary network it take into account only the presence/absence of
the link, if a "weight" attribute is provided it asses the
perturbation of the edge weight given the presence/absence on the
given subsampling.
Sd
: is the degree stability indicator. It asses the
variations of the node degree given a subsampling perturbation on
the data.
Parallel computation is provided automatically through the functions
available in the parallel package included by default from R
2.15. Support for parallel computation is available only on multi-core
machines not on high performace computing facility.
If n.cores
is set to NULL
it searches for multiple cores
on the machine, if it finds more than 2 cores the computation is
parallelized using the maximum number of cores available - 1.
If n.cores
is a numeric value it checks if the number of cores provided
is suitable for the machine where R is running. If the number of
cores requested is bigger than the available cores n.cores
will
be set to NULL
, otherwise the computation will be equally
distributed on the number of cores provided.
In case indicator
is set to all
or SI
, parameter
n.cores
will pass to the low level function which compute
the mutual distances, netdist.
netdist
, mat2adj
, WGCNA
, minet
myrawdata <- matrix(rnorm(200),ncol=20)
sstab <- netSI(myrawdata, d="HIM", n.cores=1, save=FALSE)
print(sstab$S)
print(sstab$SI)
Run the code above in your browser using DataLab