| DiffusionMap-class | R Documentation |
The provided data can be a double matrix of expression data or a data.frame with all non-integer (double) columns being treated as expression data features (and the others ignored), an ExpressionSet, or a SingleCellExperiment.
DiffusionMap(
data = stopifnot_distmatrix(distance),
sigma = "local",
k = find_dm_k(dataset_n_observations(data, distance) - 1L),
n_eigs = min(20L, dataset_n_observations(data, distance) - 2L),
density_norm = TRUE,
...,
distance = c("euclidean", "cosine", "rankcor", "l2"),
n_pcs = NULL,
n_local = seq(to = min(k, 7L), length.out = min(k, 3L)),
rotate = FALSE,
censor_val = NULL,
censor_range = NULL,
missing_range = NULL,
vars = NULL,
knn_params = list(),
verbose = !is.null(censor_range),
suppress_dpt = FALSE
)
data |
Expression data to be analyzed and covariates. Provide |
sigma |
Diffusion scale parameter of the Gaussian kernel. One of |
k |
Number of nearest neighbors to consider (default: a guess betweeen 100 and |
n_eigs |
Number of eigenvectors/values to return (default: 20) |
density_norm |
logical. If TRUE, use density normalisation |
... |
Unused. All parameters to the right of the |
distance |
Distance measurement method applied to |
n_pcs |
Number of principal components to compute to base calculations on. Using e.g. 50 DCs results in more regular looking diffusion maps.
The default NULL will not compute principal components, but use |
n_local |
If |
rotate |
logical. If TRUE, rotate the eigenvalues to get a slimmer diffusion map |
censor_val |
Value regarded as uncertain. Either a single value or one for every dimension (Optional, default: censor_val) |
censor_range |
Uncertainity range for censoring (Optional, default: none). A length-2-vector of certainty range start and end. TODO: also allow |
missing_range |
Whole data range for missing value model. Has to be specified if NAs are in the data |
vars |
Variables (columns) of the data to use. Specifying NULL will select all columns (default: All floating point value columns) |
knn_params |
Parameters passed to |
verbose |
Show a progressbar and other progress information (default: do it if censoring is enabled) |
suppress_dpt |
Specify TRUE to skip calculation of necessary (but spacious) information for |
A DiffusionMap object:
eigenvaluesEigenvalues ranking the eigenvectors
eigenvectorsEigenvectors mapping the datapoints to n_eigs dimensions
sigmasSigmas object with either information about the find_sigmas heuristic run or just local or optimal_sigma.
data_envEnvironment referencing the data used to create the diffusion map
eigenvec0First (constant) eigenvector not included as diffusion component.
transitionsTransition probabilities. Can be NULL
dDensity vector of transition probability matrix
d_normDensity vector of normalized transition probability matrix
kThe k parameter for kNN
n_pcsNumber of principal components used in kNN computation (NA if raw data was used)
n_localThe n_localth nearest neighbor(s) is/are used to determine local kernel density
density_normWas density normalization used?
rotateWere the eigenvectors rotated?
distanceDistance measurement method used
censor_valCensoring value
censor_rangeCensoring range
missing_rangeWhole data range for missing value model
varsVars parameter used to extract the part of the data used for diffusion map creation
knn_paramsParameters passed to find_knn
DiffusionMap methods to get and set the slots. find_sigmas to pre-calculate a fitting global sigma parameter
data(guo)
DiffusionMap(guo)
DiffusionMap(guo, 13, censor_val = 15, censor_range = c(15, 40), verbose = TRUE)
covars <- data.frame(covar1 = letters[1:100])
dists <- dist(matrix(rnorm(100*10), 100))
DiffusionMap(covars, distance = dists)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.