normalize_total
Normalize per-cell counts to a consistent total, either by median or a specified target sum. Optionally exclude highly expressed genes and apply adjustments to specific layers in single-cell RNA sequencing data.
Instructions
Normalize counts per cell to the same total count
Input Schema
Name | Required | Description | Default |
---|---|---|---|
exclude_highly_expressed | No | Exclude highly expressed genes for the computation of the normalization factor for each cell. | |
inplace | No | Whether to update adata or return dictionary with normalized copies. | |
key_added | No | Name of the field in adata.obs where the normalization factor is stored. | |
layer | No | Layer to normalize instead of X. If None, X is normalized. | |
layer_norm | No | Specifies how to normalize layers. | |
layers | No | List of layers to normalize. If 'all', normalize all layers. | |
max_fraction | No | If exclude_highly_expressed=True, consider cells as highly expressed that have more counts than max_fraction of the original total counts in at least one cell. | |
target_sum | No | If None, after normalization, each cell has a total count equal to the median of total counts before normalization. If a number is provided, each cell will have this total count after normalization. |
Input Schema (JSON Schema)
{
"description": "Input schema for the normalize_total preprocessing tool.",
"properties": {
"exclude_highly_expressed": {
"default": false,
"description": "Exclude highly expressed genes for the computation of the normalization factor for each cell.",
"title": "Exclude Highly Expressed",
"type": "boolean"
},
"inplace": {
"default": true,
"description": "Whether to update adata or return dictionary with normalized copies.",
"title": "Inplace",
"type": "boolean"
},
"key_added": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Name of the field in adata.obs where the normalization factor is stored.",
"title": "Key Added"
},
"layer": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Layer to normalize instead of X. If None, X is normalized.",
"title": "Layer"
},
"layer_norm": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Specifies how to normalize layers.",
"title": "Layer Norm"
},
"layers": {
"anyOf": [
{
"const": "all",
"type": "string"
},
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "List of layers to normalize. If 'all', normalize all layers.",
"title": "Layers"
},
"max_fraction": {
"default": 0.05,
"description": "If exclude_highly_expressed=True, consider cells as highly expressed that have more counts than max_fraction of the original total counts in at least one cell.",
"exclusiveMinimum": 0,
"maximum": 1,
"title": "Max Fraction",
"type": "number"
},
"target_sum": {
"anyOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"default": null,
"description": "If None, after normalization, each cell has a total count equal to the median of total counts before normalization. If a number is provided, each cell will have this total count after normalization.",
"title": "Target Sum"
}
},
"title": "NormalizeTotalModel",
"type": "object"
}