Constructor
new CustomSelectionsStandalone(normalized, optionsopt)
- Source:
Parameters:
Name | Type | Attributes | Default | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
normalized |
external:MultiMatrix | A MultiMatrix of log-normalized values for multiple modalities. |
||||||||||||
options |
object |
<optional> |
{}
|
Optional parameters. Properties
|
Classes
Methods
addSelection(id, selection, optionsopt)
- Description:
Add a custom selection and compute its markers. Users should run
compute
at least once before calling this function.
- Source:
Parameters:
Name | Type | Attributes | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
id |
string | A unique identifier for the new custom selection. |
|||||||||||
selection |
Array | TypedArray | The indices of the cells in the selection. |
|||||||||||
options |
object |
<optional> |
Optional parameters. Properties
|
Returns:
The custom selection is added to the state and calculation of its markers is performed. Nothing is returned.
computeVersus(left, right) → {object}
- Description:
Extract markers for a pairwise comparison between two selections, for more detailed examination of the differences between them.
- Source:
Parameters:
Name | Type | Description |
---|---|---|
left |
string | Identifier of one selection in which to find upregulated markers. |
right |
string | Identifier of another selection to be compared against |
Returns:
Object containing:
results
: object containing the marker statistics for the comparison between two clusters. Each key is a modality name and each value is a ScoreMarkersResults object.left
: index of the group corresponding to theleft
selection in each ScoreMarkersResults object. e.g., Cohen's d for the RNA markers of theleft
selection are defined asoutput.results.RNA.cohen(output.left)
.right
: index of the group corresponding to theright
selection in each ScoreMarkersResults object. e.g., Cohen's d for the RNA markers of theright
selection are defined asoutput.results.RNA.cohen(output.right)
.
- Type
- object
fetchBlockLevels(optionsopt) → {Array}
- Source:
Parameters:
Name | Type | Attributes | Default | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
object |
<optional> |
{}
|
Optional parameters. Properties
|
Returns:
Array of levels for the blocking factor.
Block indices in the ScoreMarkersResults instances returned by fetchResults
can be cross-referenced to this array.
- Type
- Array
fetchParameters() → {object}
- Source:
Returns:
Object containing the parameters.
- Type
- object
fetchResults(id) → {object}
- Source:
Parameters:
Name | Type | Description |
---|---|---|
id |
string | An identifier for the desired selection. |
Returns:
Object containing the markers for the desired selection. Each key is a modality name while each value is a ScoreMarkersResults object, containing the marker detection results across all features of the corresponding modality. The set of cells in the selection is denoted as group 1, while all cells outside of the selection are denoted as group 0.
- Type
- object
fetchSelectionIndices(id, optionsopt) → {Array|TypedArray}
- Description:
Retrieve the indices for a selection of interest.
- Source:
Parameters:
Name | Type | Attributes | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
id |
string | The identifier for the selection. |
|||||||||||
options |
object |
<optional> |
Optional parameters. Properties
|
Returns:
Array of indices in the requested selection.
- Type
- Array | TypedArray
fetchSelections(optionsopt, forceopt, nullable) → {object}
- Description:
Retrieve indices for all selections.
- Source:
Parameters:
Name | Type | Attributes | Default | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
object |
<optional> |
Optional parameters. Properties
|
|||||||||||
force |
string |
<optional> <nullable> |
null
|
Whether to force each |
Returns:
Object where the keys are the selection names and the values are arrays of indices for each selection. Each array is a copy and can be modified without affecting the CustomSelectionsState.
- Type
- object
free()
- Description:
Frees all resources associated with this instance.
- Source:
removeSelection(id)
- Description:
Remove a custom selection and its results from the state.
- Source:
Parameters:
Name | Type | Description |
---|---|---|
id |
string | An identifier for the selection to be removed. |
Returns:
The specified selection and its results are removed from the state. Nothing is returned.
setParameters(parameters)
- Description:
If this method is not called, the parameters default to those in
CustomSelectionsState.defaults
.
- Source:
Parameters:
Name | Type | Description |
---|---|---|
parameters |
object | Parameter object, see the argument of the same name in |
Returns:
The state is updated with the new parameters.