From 24b27e5da5b3117b5dcb856a5dd02473c414da0e Mon Sep 17 00:00:00 2001 From: Oren Ben-Kiki Date: Thu, 20 Jun 2024 21:08:46 +0300 Subject: [PATCH] Add compute_boxes_data. --- docs/v0.1.0/.documenter-siteinfo.json | 2 +- docs/v0.1.0/boxes.html | 96 ++++++++++++++++++++++++-- docs/v0.1.0/identify_genes.html | 10 +-- docs/v0.1.0/index.html | 6 ++ docs/v0.1.0/objects.inv | Bin 723 -> 737 bytes docs/v0.1.0/search_index.js | 2 +- src/boxes.jl | 25 +++++++ src/boxes.md | 1 + src/contracts.jl | 42 ++++++----- 9 files changed, 153 insertions(+), 31 deletions(-) diff --git a/docs/v0.1.0/.documenter-siteinfo.json b/docs/v0.1.0/.documenter-siteinfo.json index d638b2d..2917399 100644 --- a/docs/v0.1.0/.documenter-siteinfo.json +++ b/docs/v0.1.0/.documenter-siteinfo.json @@ -1 +1 @@ -{"documenter":{"julia_version":"1.10.4","generation_timestamp":"2024-06-20T17:56:23","documenter_version":"1.4.1"}} \ No newline at end of file +{"documenter":{"julia_version":"1.10.4","generation_timestamp":"2024-06-20T21:08:18","documenter_version":"1.4.1"}} \ No newline at end of file diff --git a/docs/v0.1.0/boxes.html b/docs/v0.1.0/boxes.html index 646eb3f..39e0e1b 100644 --- a/docs/v0.1.0/boxes.html +++ b/docs/v0.1.0/boxes.html @@ -245,11 +245,11 @@

gene @ divergence -::AbstractFloat (required): Scale fold factors of each gene by multiplying with (1 - divergence) of the gene. +::Union{Float32, Float64} (required): Scale fold factors of each gene by multiplying with (1 - divergence) of the gene.

metacell @ total_UMIs -::Unsigned (required): The total number of UMIs used to estimate the fraction of all the genes in each metacell. +::Union{UInt16, UInt32, UInt64, UInt8} (required): The total number of UMIs used to estimate the fraction of all the genes in each metacell.

Matrices @@ -257,11 +257,11 @@

gene, metacell @ fraction -::AbstractFloat (required): The estimated fraction of the UMIs of each gene in each metacell. +::Union{Float32, Float64} (required): The estimated fraction of the UMIs of each gene in each metacell.

gene, metacell @ total_UMIs -::Unsigned (required): The total number of UMIs used to estimate the fraction of each gene in each metacell. +::Union{UInt16, UInt32, UInt64, UInt8} (required): The total number of UMIs used to estimate the fraction of each gene in each metacell.

Outputs @@ -293,7 +293,7 @@

neighborhood @ span -::AbstractFloat (guaranteed): The span (fold factor) used to compute the neighborhood. +::Union{Float32, Float64} (guaranteed): The span (fold factor) used to compute the neighborhood.

Matrices @@ -305,7 +305,7 @@

box, box @ distance -::AbstractFloat (guaranteed): The distance (fold factor) between the most different metacell genes between the boxes. +::Union{Float32, Float64} (guaranteed): The distance (fold factor) between the most different metacell genes between the boxes.

box, neighborhood @ is_member @@ -314,6 +314,84 @@

+
+
+ + + +Metacells.Boxes.compute_boxes_data! + + — +Function + +
+
+
+
+function compute_boxes_data!(daf::DafWriter)::Nothing
+
+
+

Compute aggregated per-box data based on per-metacell data. This is separated from + +compute_boxes! + + to allow computing this data for all genes (instead of just for the subset of genes fed to + +compute_boxes! + +). +

+

+Inputs + +

+

+Axes + +

+

+gene + (required): Sequenced genes. +

+

+metacell + (required): Minimal-sized groups of cells for robust point estimates. +

+

+box + (required): Distinct groups of metacells with "very close" estimated cell state. +

+

+Matrices + +

+

+gene, metacell @ fraction +::Union{Float32, Float64} (required): The estimated fraction of the UMIs of each gene in each metacell. +

+

+gene, metacell @ total_UMIs +::Union{UInt16, UInt32, UInt64, UInt8} (required): The total number of UMIs used to estimate the fraction of each gene in each metacell. +

+

+Outputs + +

+

+Matrices + +

+

+gene, box @ fraction +::Union{Float32, Float64} (guaranteed): The estimated fraction of the UMIs of each gene in each box. +

+

+gene, box @ total_UMIs +::Union{UInt16, UInt32, UInt64, UInt8} (guaranteed): The total number of UMIs used to estimate the fraction of each gene in each box. +

+
+
+

Index @@ -335,6 +413,12 @@

+
  • + +Metacells.Boxes.compute_boxes_data! + + +