From 110d87d18d40deb8cdf68e71d3d1d2e3c9295c70 Mon Sep 17 00:00:00 2001 From: Francesco Terenzi Date: Thu, 4 Apr 2024 15:32:12 +0100 Subject: [PATCH] v4.3.5 --- CHANGELOG.md | 3 + Cargo.lock | 2 +- Cargo.toml | 2 +- docs/hsc/all.html | 2 +- docs/hsc/constant.MAX_SUBCLONES.html | 2 +- docs/hsc/constant.TIME_AT_BIRTH.html | 2 +- docs/hsc/enum.Probs.html | 2 +- docs/hsc/fn.write2file.html | 2 +- docs/hsc/genotype/index.html | 2 +- .../hsc/genotype/struct.MutationalBurden.html | 2 +- .../struct.NeutralMutationPoisson.html | 2 +- docs/hsc/genotype/struct.Sfs.html | 2 +- docs/hsc/genotype/type.Variant.html | 2 +- docs/hsc/index.html | 2 +- docs/hsc/process/enum.SavingCells.html | 2 +- docs/hsc/process/enum.Stats2Save.html | 2 +- docs/hsc/process/index.html | 2 +- .../struct.CellDivisionProbabilities.html | 2 +- docs/hsc/process/struct.Exponential.html | 2 +- docs/hsc/process/struct.Moran.html | 2 +- docs/hsc/process/struct.ProcessOptions.html | 2 +- docs/hsc/process/struct.SavingOptions.html | 2 +- docs/hsc/process/struct.Snapshot.html | 2 +- docs/hsc/proliferation/enum.Division.html | 2 +- .../proliferation/enum.NeutralMutations.html | 4 +- docs/hsc/proliferation/index.html | 2 +- .../proliferation/struct.Proliferation.html | 4 +- .../fn.assign_background_mutations.html | 2 +- .../fn.assign_divisional_mutations.html | 2 +- docs/hsc/stemcell/index.html | 2 +- docs/hsc/stemcell/struct.StemCell.html | 2 +- docs/hsc/struct.ProbsPerYear.html | 2 +- docs/hsc/subclone/enum.Fitness.html | 2 +- .../fn.from_mean_std_to_shape_scale.html | 2 +- docs/hsc/subclone/fn.next_clone.html | 9 +- docs/hsc/subclone/fn.proliferating_cell.html | 2 +- .../subclone/fn.save_variant_fraction.html | 2 +- docs/hsc/subclone/index.html | 5 +- docs/hsc/subclone/struct.Distributions.html | 2 +- docs/hsc/subclone/struct.SubClone.html | 2 +- docs/hsc/subclone/struct.SubClones.html | 16 +- docs/hsc/subclone/struct.Variants.html | 6 +- docs/hsc/subclone/type.CloneId.html | 2 +- docs/search-index.js | 2 +- docs/src/hsc/process.rs.html | 4 +- docs/src/hsc/proliferation.rs.html | 142 +++++++++++++++--- docs/src/hsc/subclone.rs.html | 76 +--------- docs/trait.impl/core/clone/trait.Clone.js | 2 +- docs/trait.impl/core/default/trait.Default.js | 2 +- docs/trait.impl/core/fmt/trait.Debug.js | 2 +- docs/trait.impl/core/marker/trait.Copy.js | 2 +- src/process.rs | 4 +- src/proliferation.rs | 90 ++++++++--- src/subclone.rs | 44 +----- 54 files changed, 279 insertions(+), 210 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5ba1fc24..f7d96553 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ # Changelog The semantic versioning is kind of random. +## 4.3.5 +- reintroduce the factor 2 for the fit variants to avoid "initiating fit variants at size 2, instead of 1" + ## 4.3.4 ### BugFix - first sample fit variant (clone) for the parental cell, then assigned both cells to that sampled clone, this justifies removing the factor 2 diff --git a/Cargo.lock b/Cargo.lock index f936a621..7e7aa9a4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -311,7 +311,7 @@ checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" [[package]] name = "hsc" -version = "4.3.4" +version = "4.3.5" dependencies = [ "anyhow", "chrono", diff --git a/Cargo.toml b/Cargo.toml index 5dfa7eaf..cd352083 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hsc" -version = "4.3.4" +version = "4.3.5" edition = "2021" [dependencies] diff --git a/docs/hsc/all.html b/docs/hsc/all.html index fb75f11e..2376012a 100644 --- a/docs/hsc/all.html +++ b/docs/hsc/all.html @@ -1 +1 @@ -List of all items in this crate
\ No newline at end of file +List of all items in this crate
\ No newline at end of file diff --git a/docs/hsc/constant.MAX_SUBCLONES.html b/docs/hsc/constant.MAX_SUBCLONES.html index 5be9bf3c..2c222c8b 100644 --- a/docs/hsc/constant.MAX_SUBCLONES.html +++ b/docs/hsc/constant.MAX_SUBCLONES.html @@ -1,4 +1,4 @@ -MAX_SUBCLONES in hsc - Rust

Constant hsc::MAX_SUBCLONES

source ·
pub const MAX_SUBCLONES: usize = 1200;
Expand description

Maximal number of fit clones that can arise during the simulation.

+MAX_SUBCLONES in hsc - Rust

Constant hsc::MAX_SUBCLONES

source ·
pub const MAX_SUBCLONES: usize = 1200;
Expand description

Maximal number of fit clones that can arise during the simulation.

If the parameters of the simulation provided by the user (e.g. fit mutation rate) are too extreme, the program will exit with error. To avoid this, increase here the number of clones.

diff --git a/docs/hsc/constant.TIME_AT_BIRTH.html b/docs/hsc/constant.TIME_AT_BIRTH.html index 6e1ba5ba..4da52ba0 100644 --- a/docs/hsc/constant.TIME_AT_BIRTH.html +++ b/docs/hsc/constant.TIME_AT_BIRTH.html @@ -1,3 +1,3 @@ -TIME_AT_BIRTH in hsc - Rust

Constant hsc::TIME_AT_BIRTH

source ·
pub const TIME_AT_BIRTH: f32 = _; // 0.75f32
Expand description

The time at birth measured in years used for background mutations in the +TIME_AT_BIRTH in hsc - Rust

Constant hsc::TIME_AT_BIRTH

source ·
pub const TIME_AT_BIRTH: f32 = _; // 0.75f32
Expand description

The time at birth measured in years used for background mutations in the exponential growing phase.

\ No newline at end of file diff --git a/docs/hsc/enum.Probs.html b/docs/hsc/enum.Probs.html index a758712b..659205bf 100644 --- a/docs/hsc/enum.Probs.html +++ b/docs/hsc/enum.Probs.html @@ -1,4 +1,4 @@ -Probs in hsc - Rust

Enum hsc::Probs

source ·
pub enum Probs {
+Probs in hsc - Rust

Enum hsc::Probs

source ·
pub enum Probs {
     Asymmetric {
         u: f32,
         probs_per_year: ProbsPerYear,
diff --git a/docs/hsc/fn.write2file.html b/docs/hsc/fn.write2file.html
index c4db5b58..a71f3658 100644
--- a/docs/hsc/fn.write2file.html
+++ b/docs/hsc/fn.write2file.html
@@ -1,4 +1,4 @@
-write2file in hsc - Rust

Function hsc::write2file

source ·
pub fn write2file<T: Display>(
+write2file in hsc - Rust

Function hsc::write2file

source ·
pub fn write2file<T: Display>(
     data: &[T],
     path: &Path,
     header: Option<&str>,
diff --git a/docs/hsc/genotype/index.html b/docs/hsc/genotype/index.html
index 6346009c..bf91ce5a 100644
--- a/docs/hsc/genotype/index.html
+++ b/docs/hsc/genotype/index.html
@@ -1,4 +1,4 @@
-hsc::genotype - Rust

Module hsc::genotype

source ·
Expand description

The neutral mutations representing the genotype of the stem cells.

+hsc::genotype - Rust

Module hsc::genotype

source ·
Expand description

The neutral mutations representing the genotype of the stem cells.

Structs

  • Single-cell mutational burden is a mapping of cells sharing a number of mutations.
  • The Poisson probability distribution modeling the appearance of neutral mutations, which are assumed to follow a diff --git a/docs/hsc/genotype/struct.MutationalBurden.html b/docs/hsc/genotype/struct.MutationalBurden.html index 2ed11aff..77a96aae 100644 --- a/docs/hsc/genotype/struct.MutationalBurden.html +++ b/docs/hsc/genotype/struct.MutationalBurden.html @@ -1,4 +1,4 @@ -MutationalBurden in hsc::genotype - Rust
    pub struct MutationalBurden(pub FxHashMap<u16, u64>);
    Expand description

    Single-cell mutational burden is a mapping of cells sharing a number of +MutationalBurden in hsc::genotype - Rust

    pub struct MutationalBurden(pub FxHashMap<u16, u64>);
    Expand description

    Single-cell mutational burden is a mapping of cells sharing a number of mutations.

    To plot it, plot on the x-axis the keys (number of mutations) and on the y-axis the values (the number of cells with those mutations).

    diff --git a/docs/hsc/genotype/struct.NeutralMutationPoisson.html b/docs/hsc/genotype/struct.NeutralMutationPoisson.html index 4d61368b..eab12f9e 100644 --- a/docs/hsc/genotype/struct.NeutralMutationPoisson.html +++ b/docs/hsc/genotype/struct.NeutralMutationPoisson.html @@ -1,4 +1,4 @@ -NeutralMutationPoisson in hsc::genotype - Rust
    pub struct NeutralMutationPoisson {
    +NeutralMutationPoisson in hsc::genotype - Rust
    pub struct NeutralMutationPoisson {
         pub lambda_background: f32,
         pub lambda_division: f32,
         /* private fields */
    diff --git a/docs/hsc/genotype/struct.Sfs.html b/docs/hsc/genotype/struct.Sfs.html
    index 9936013c..ebd273f2 100644
    --- a/docs/hsc/genotype/struct.Sfs.html
    +++ b/docs/hsc/genotype/struct.Sfs.html
    @@ -1,4 +1,4 @@
    -Sfs in hsc::genotype - Rust

    Struct hsc::genotype::Sfs

    source ·
    pub struct Sfs(pub FxHashMap<u64, u64>);
    Expand description

    Site frequency spectrum +Sfs in hsc::genotype - Rust

    Struct hsc::genotype::Sfs

    source ·
    pub struct Sfs(pub FxHashMap<u64, u64>);
    Expand description

    Site frequency spectrum implemented as mapping with keys being j cells (x-axis) and values being the number of variants with j cells (y-axis).

    Tuple Fields§

    §0: FxHashMap<u64, u64>

    Implementations§

    source§

    impl Sfs

    source

    pub fn from_cells(cells: &[&StemCell], verbosity: u8) -> Result<Self>

    Compute the SFS from the stem cell population.

    diff --git a/docs/hsc/genotype/type.Variant.html b/docs/hsc/genotype/type.Variant.html index 94eaf9e8..4dda945e 100644 --- a/docs/hsc/genotype/type.Variant.html +++ b/docs/hsc/genotype/type.Variant.html @@ -1 +1 @@ -Variant in hsc::genotype - Rust

    Type Alias hsc::genotype::Variant

    source ·
    pub type Variant = Uuid;

    Aliased Type§

    struct Variant(/* private fields */);
    \ No newline at end of file +Variant in hsc::genotype - Rust

    Type Alias hsc::genotype::Variant

    source ·
    pub type Variant = Uuid;

    Aliased Type§

    struct Variant(/* private fields */);
    \ No newline at end of file diff --git a/docs/hsc/index.html b/docs/hsc/index.html index 9bf2c6d9..db9d4894 100644 --- a/docs/hsc/index.html +++ b/docs/hsc/index.html @@ -1,4 +1,4 @@ -hsc - Rust