UMI Matrix Sparsity

Measure sparsity of a cell-by-gene UMI count matrix.

Description

Sparsity is the fraction of zero matrix entries.

Sparsity is the fraction of zero matrix entries. In a cell-by-gene UMI matrix, nonzero detection and expression magnitude are separate properties.1

Measure sparsity of a cell-by-gene UMI count matrix.

When to use UMI Matrix Sparsity

Use this tool to measure sparsity of a cell-by-gene UMI count matrix.

Prepare the upstream counts, expression values, sequences or record lists requested by this tool. Keep corresponding features in the same order and confirm count units, transformations and caller-selected criteria.

How to use UMI Matrix Sparsity and understand its results

  1. Prepare the upstream counts, expression values, sequences or record lists requested by this tool. Keep corresponding features in the same order and confirm count units, transformations and caller-selected criteria.
  2. Enter cellGeneCounts using the field table and calculation rules, then run the tool.
  3. Read nonzeroCount, totalEntries, sparsityPercent. The explanation below defines the units, signs, ordering and any flags or placeholder values.
  4. If the tool reports an input issue, correct the values and run it again. Apply the stated assumptions when interpreting a successfully returned result.
Input fieldMeaningValue type; see rules belowRequirement
cellGeneCountsCell gene countslist of list of numberRequired

Enter a nonempty rectangular cell-row/gene-column matrix of nonnegative counts. Count exact nonzero entries and all entries, then return both counts and zero percentage. An all-zero matrix has 100% sparsity.

sparsity%=100(totalEntries−nonzeroEntries)/totalEntries

Units, indexing, boundary conditions and exceptional cases are defined in the calculation rules above.

Output fieldMeaningValue type
nonzeroCountNonzero countnumber
totalEntriesTotal entriesnumber
sparsityPercentSparsity percentnumber
json
{
  "input": {
    "cellGeneCounts": [
      [
        1,
        0
      ],
      [
        0,
        2
      ]
    ]
  },
  "output": {
    "nonzeroCount": 2,
    "totalEntries": 4,
    "sparsityPercent": 50
  }
}

Limitations and assumptions

Fractional nonnegative values are accepted. No filtering, sparse-file import, biological dropout model or distinction between technical zeros and true absence is applied.

Numeric inputs must be finite. Follow the calculation-specific rules for overflow, underflow and exceptional cases. Matrices are limited to 128 rows and 128 entries per row; other lists are limited to 100,000 entries. Missing required fields, extra fields, wrong value types and violations of the calculation rules are input errors.

Alternative or Complementary methods

Use Marker Expression Fraction: Summarize a marker dot plot’s detection share and mean expression. For a complementary task, use Empty Droplet Filter: Classify droplets by a caller-supplied minimum UMI count.

References

  1. UMI Matrix Sparsity — tool.io

Similar or alternative tools

Don't forget to set a bookmark for tool.io!
Privacy | Imprint | Cookies