-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #21 from pawelqs/develop
Develop
- Loading branch information
Showing
92 changed files
with
3,493 additions
and
3,065 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
Package: cevomod | ||
Title: Cancer Evolution Models | ||
Version: 1.1.0 | ||
Version: 2.0.0 | ||
Authors@R: | ||
person("Paweł", "Kuś", , "[email protected]", role = c("aut", "cre"), | ||
comment = c(ORCID = "0000-0002-4367-9821")) | ||
|
@@ -9,7 +9,7 @@ Description: Cancer Evolutionary Models. Set of methods facilitating the analysi | |
License: GPL (>= 3) | ||
Encoding: UTF-8 | ||
Roxygen: list(markdown = TRUE) | ||
RoxygenNote: 7.2.2 | ||
RoxygenNote: 7.2.3 | ||
Suggests: | ||
BMix, | ||
circlize, | ||
|
@@ -61,4 +61,4 @@ Remotes: | |
caravagnalab/mobster, | ||
caravagnalab/BMix | ||
LazyData: true | ||
URL: https://pawelqs.github.io/cevomod/ | ||
URL: https://pawelqs.github.io/cevomod/, https://github.com/pawelqs/cevomod |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,17 @@ | ||
|
||
# cevomod 1.x.x | ||
## cevomod 2.0.0 | ||
* cevomod functions can no utilize VAF or CCF (Cancer Cell Fraction) as a measure | ||
of mutation frequency. CCF is calculated using the formula introduced in [Dentro et al. *Principles of Reconstructing the Subclonal Architecture of Cancers* (2015)](https://doi.org/10.1101/cshperspect.a026625) | ||
|
||
**cevomod 1.1.0** | ||
|
||
## cevomod 1.1.0 | ||
* cevodata export to [CliP](https://github.com/wwylab/CliP) implemented | ||
|
||
**cevomod 1.0.0** | ||
|
||
## cevomod 1.0.0 | ||
* cevodata class implementation | ||
* fitting the power-law tails with exponent equal to 2 using $M(f) \sim 1/f$ statistic | ||
* fitting the power-law tails with optimized exponent | ||
* fitting subclones using mclust | ||
* fitting subclones using BMix | ||
* calculation of the evolutionary parameters using the [Williams et al. (2018)](https://doi.org/10.1038/s41588-018-0128-6) equations and the [MOBSTER code](https://github.com/caravagnalab/mobster/blob/master/R/evodynamics.R) [(Caravagna et al. (2020))](https://doi.org/10.1038/s41588-020-0675-5) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
|
||
#' Annotate chromosome ploidies in CNV data | ||
#' | ||
#' Adds the normal_cn column to the data. This column is required for e.g. | ||
#' by Dentro CCF calculation method. Requires 'sex' column in the metadata. | ||
#' Males should be encoded by 'M' or "male'. | ||
#' | ||
#' @param object <cevodata> object | ||
#' @param which_cnvs Name of the CNVs slot | ||
#' | ||
#' @return <cevodata> object | ||
#' @export | ||
annotate_normal_cn <- function(object, which_cnvs = default_CNVs(object)) { | ||
msg("Assuming human genome") | ||
cnvs <- CNVs(object, which_cnvs) |> | ||
left_join(get_patient_sex(object), by = "sample_id") |> | ||
mutate( | ||
normal_cn = if_else( | ||
.data$sex %in% c("male", "M") & .data$chrom %in% c("chrX", "chrY"), 1, 2 | ||
) | ||
) | ||
object |> | ||
add_CNV_data(cnvs, name = which_cnvs) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
|
||
cevomod_global <- new.env(parent = emptyenv()) | ||
cevomod_global$verbosity_level <- 1 | ||
|
||
|
||
#' Get the verbosity level | ||
#' @export | ||
get_cevomod_verbosity <- function() { | ||
cevomod_global$verbosity_level | ||
} | ||
|
||
|
||
#' Change the verbosity level | ||
#' @param verbosity_level Verbosity level to use: | ||
#' 0 - silent | ||
#' 1 - normal | ||
#' 2 - detailed (in some cases) | ||
#' @export | ||
set_cevomod_verbosity <- function(verbosity_level = 1) { | ||
old <- cevomod_global$verbosity_level | ||
cevomod_global$verbosity_level <- verbosity_level | ||
invisible(old) | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.