From 10dbe6859c0aada873e86696dcc2ae07bb368c7f Mon Sep 17 00:00:00 2001 From: danro9685 Date: Wed, 18 Jul 2018 08:22:23 -0700 Subject: [PATCH 1/8] version update --- DESCRIPTION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DESCRIPTION b/DESCRIPTION index 0b94fcb..d4fab6e 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,5 +1,5 @@ Package: SparseSignatures -Version: 1.0.2 +Version: 1.1.2 Date: 2018-07-18 Title: SparseSignatures Authors@R: c(person("Daniele", "Ramazzotti", role=c("cre","aut"),email="daniele.ramazzotti@yahoo.com"), From 4a6173de370a500c4bfacf799465c7f524e0174d Mon Sep 17 00:00:00 2001 From: luca-dex Date: Tue, 18 Sep 2018 10:13:11 +0300 Subject: [PATCH 2/8] update roxygen --- DESCRIPTION | 2 +- man/evaluate.lambda.range.Rd | 8 ++++---- man/nmf.LassoCV.Rd | 10 +++++----- man/nmf.LassoK.Rd | 7 ++++--- 4 files changed, 14 insertions(+), 13 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index d4fab6e..3235cd0 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -41,5 +41,5 @@ URL: https://github.com/danro9685/SparseSignatures BugReports: https://github.com/danro9685/SparseSignatures biocViews: BiomedicalInformatics, SomaticMutation -RoxygenNote: 6.0.1 +RoxygenNote: 6.1.0 VignetteBuilder: knitr diff --git a/man/evaluate.lambda.range.Rd b/man/evaluate.lambda.range.Rd index 80f33e3..b83e164 100644 --- a/man/evaluate.lambda.range.Rd +++ b/man/evaluate.lambda.range.Rd @@ -4,10 +4,10 @@ \alias{evaluate.lambda.range} \title{evaluate.lambda.range} \usage{ -evaluate.lambda.range(x, K = 6, beta = NULL, background_signature = NULL, - nmf_runs = 10, lambda_values = c(0.1, 0.2, 0.3, 0.4, 0.5), - iterations = 20, max_iterations_lasso = 10000, num_processes = Inf, - seed = NULL, verbose = TRUE) +evaluate.lambda.range(x, K = 6, beta = NULL, + background_signature = NULL, nmf_runs = 10, lambda_values = c(0.1, + 0.2, 0.3, 0.4, 0.5), iterations = 20, max_iterations_lasso = 10000, + num_processes = Inf, seed = NULL, verbose = TRUE) } \arguments{ \item{x}{count matrix.} diff --git a/man/nmf.LassoCV.Rd b/man/nmf.LassoCV.Rd index 1ee1502..3a030aa 100644 --- a/man/nmf.LassoCV.Rd +++ b/man/nmf.LassoCV.Rd @@ -5,11 +5,11 @@ \title{nmf.LassoCV} \usage{ nmf.LassoCV(x, K = 3:10, starting_beta = NULL, - background_signature = NULL, nmf_runs = 10, lambda_values = c(0.1, 0.2, - 0.3), cross_validation_entries = 0.05, cross_validation_iterations = 5, - cross_validation_repetitions = 10, iterations = 20, - max_iterations_lasso = 10000, num_processes = Inf, seed = NULL, - verbose = TRUE) + background_signature = NULL, nmf_runs = 10, lambda_values = c(0.1, + 0.2, 0.3), cross_validation_entries = 0.05, + cross_validation_iterations = 5, cross_validation_repetitions = 10, + iterations = 20, max_iterations_lasso = 10000, num_processes = Inf, + seed = NULL, verbose = TRUE) } \arguments{ \item{x}{count matrix.} diff --git a/man/nmf.LassoK.Rd b/man/nmf.LassoK.Rd index 1b7f303..5751e13 100644 --- a/man/nmf.LassoK.Rd +++ b/man/nmf.LassoK.Rd @@ -4,9 +4,10 @@ \alias{nmf.LassoK} \title{nmf.LassoK} \usage{ -nmf.LassoK(x, K, beta = NULL, background_signature = NULL, nmf_runs = 10, - lambda_rate = 0.2, iterations = 20, max_iterations_lasso = 10000, - num_processes = Inf, parallel = NULL, seed = NULL, verbose = TRUE) +nmf.LassoK(x, K, beta = NULL, background_signature = NULL, + nmf_runs = 10, lambda_rate = 0.2, iterations = 20, + max_iterations_lasso = 10000, num_processes = Inf, parallel = NULL, + seed = NULL, verbose = TRUE) } \arguments{ \item{x}{count matrix.} From d5b5afd4cca3d2039c296b93903f8489210eb5c8 Mon Sep 17 00:00:00 2001 From: luca-dex Date: Tue, 18 Sep 2018 10:15:07 +0300 Subject: [PATCH 3/8] version update --- DESCRIPTION | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 3235cd0..11744c4 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: SparseSignatures -Version: 1.1.2 -Date: 2018-07-18 +Version: 1.1.3 +Date: 2018-09-18 Title: SparseSignatures Authors@R: c(person("Daniele", "Ramazzotti", role=c("cre","aut"),email="daniele.ramazzotti@yahoo.com"), person("Avantika", "Lal", role=c("aut")), @@ -31,7 +31,7 @@ Suggests: testthat, knitr, Name: - An R package for the extraction sparse mutational signatures from whole genome sequencing data + An R package for the extraction of sparse mutational signatures from whole genome sequencing data Description: Point mutations occurring in a genome can be divided into 96 categories based on the base being mutated, the base it is mutated into and its two flanking bases. Therefore, for any patient, it is possible to represent all the point mutations occurring in that patient’s tumor as a vector of length 96, where each element represents the count of mutations for a given category in the patient. A mutational signature represents the pattern of mutations produced by a mutagen or mutagenic process inside the cell. Each signature can also be represented by a vector of length 96, where each element represents the probability that this particular mutagenic process generates a mutation of the 96 above mentioned categories. In this R package, we provide a set of functions to extract and visualize the mutational signatures that best explain the mutation counts of a large number of patients. Encoding: UTF-8 From d09289e19fe2910801c741dfcf0ad917f93858af Mon Sep 17 00:00:00 2001 From: luca-dex Date: Tue, 18 Sep 2018 11:47:24 +0300 Subject: [PATCH 4/8] add Rbuildignore --- .Rbuildignore | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 .Rbuildignore diff --git a/.Rbuildignore b/.Rbuildignore new file mode 100644 index 0000000..e01ac89 --- /dev/null +++ b/.Rbuildignore @@ -0,0 +1,12 @@ +^README.md$ +^LICENSE.md$ +^.gitignore$ +^.travis.yml$ +^.git/.*$ + +# Vignette +inst/doc +/inst/doc/vignette.R +/inst/doc/vignette.Rnw +/vignettes/vignette.R +/cfg.R From 7bfcb986b9a0e1e45c9e93815f18b42e79bf441f Mon Sep 17 00:00:00 2001 From: luca-dex Date: Tue, 18 Sep 2018 15:20:01 +0300 Subject: [PATCH 5/8] fix Rbuildignore --- .Rbuildignore | 7 ------- 1 file changed, 7 deletions(-) diff --git a/.Rbuildignore b/.Rbuildignore index e01ac89..d4b97e1 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -3,10 +3,3 @@ ^.gitignore$ ^.travis.yml$ ^.git/.*$ - -# Vignette -inst/doc -/inst/doc/vignette.R -/inst/doc/vignette.Rnw -/vignettes/vignette.R -/cfg.R From 37f02045ba11063071ed7e63a6e2452a38290367 Mon Sep 17 00:00:00 2001 From: danro9685 Date: Fri, 21 Sep 2018 17:44:47 +0200 Subject: [PATCH 6/8] fixing #4 --- R/mutation_factor.R | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/R/mutation_factor.R b/R/mutation_factor.R index 3e9b55d..465aa53 100755 --- a/R/mutation_factor.R +++ b/R/mutation_factor.R @@ -138,19 +138,19 @@ # set the initial random values for beta if(is.null(background_signature)) { - curr_beta <- matrix(0,nrow=K,ncol=dim(x)[2]) - for(i in 1:K) { + curr_beta <- matrix(0,nrow=k,ncol=dim(x)[2]) + for(i in 1:k) { curr_beta[i,] <- runif(dim(x)[2]) } colnames(curr_beta) <- colnames(x) } else { - curr_beta <- matrix(0,nrow=(K+1),ncol=dim(x)[2]) + curr_beta <- matrix(0,nrow=(k+1),ncol=dim(x)[2]) curr_beta[1,] <- background_signature - for(i in 2:(K+1)) { + for(i in 2:(k+1)) { curr_beta[i,] <- runif(dim(x)[2]) } - rownames(curr_beta) <- c("background_signature",rep("",K)) + rownames(curr_beta) <- c("background_signature",rep("",k)) colnames(curr_beta) <- colnames(x) } @@ -185,7 +185,7 @@ if(verbose) { cat("Computing the initial values of beta by standard NMF...","\n") } - curr_beta <- basis(nmf(t(x),rank=K,nrun=nmf_runs)) + curr_beta <- basis(nmf(t(x),rank=k,nrun=nmf_runs)) curr_beta <- t(curr_beta) # add a signature to beta (leading to K+1 signatures in total) to explicitly model noise From a44412d19a83360b6d3ff74003b34e2e211b99ce Mon Sep 17 00:00:00 2001 From: luca-dex Date: Sat, 22 Sep 2018 12:22:34 +0300 Subject: [PATCH 7/8] fix #6 move NMF to Depends section --- DESCRIPTION | 6 +++--- inst/NEWS.Rd | 12 ++++++++++++ 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 11744c4..ecc1a8b 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: SparseSignatures -Version: 1.1.3 -Date: 2018-09-18 +Version: 1.1.4 +Date: 2018-09-21 Title: SparseSignatures Authors@R: c(person("Daniele", "Ramazzotti", role=c("cre","aut"),email="daniele.ramazzotti@yahoo.com"), person("Avantika", "Lal", role=c("aut")), @@ -11,8 +11,8 @@ Authors@R: c(person("Daniele", "Ramazzotti", role=c("cre","aut"),email="daniele. Maintainer: Luca De Sano Depends: R (>= 3.5), + NMF Imports: - NMF, nnlasso, nnls, parallel, diff --git a/inst/NEWS.Rd b/inst/NEWS.Rd index 0c54a53..4d458c2 100644 --- a/inst/NEWS.Rd +++ b/inst/NEWS.Rd @@ -2,6 +2,18 @@ \title{News for the package \pkg{SparseSignatures}} \encoding{UTF-8} +\section{Changes in Version 1.1.4}{ + \itemize{ + \item Move NMF to Depends section + } +} + +\section{Changes in Version 1.1.3}{ + \itemize{ + \item Issue with the basis function solved + } +} + \section{Changes in Version 1.0.0}{ \itemize{ \item Package released on Bioconductor in May 2018. From 1d8cb8bb6669d164f68184f84fe209c48d6c556b Mon Sep 17 00:00:00 2001 From: luca-dex Date: Sat, 22 Sep 2018 12:37:05 +0300 Subject: [PATCH 8/8] report test coverage to codecov --- .travis.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.travis.yml b/.travis.yml index cba6889..74d954e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -15,3 +15,9 @@ branches: only: - master - development + +r_packages: + - covr + +after_success: + - Rscript -e 'library(covr); codecov()'