# HG changeset patch # User artbio # Date 1603403268 0 # Node ID 7954f0d3517f5ccae61b8b21a1a3f1eec68689d3 # Parent 7995a949189fe9cb8fa5c1573538c3a030e73024 "planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/mutational_patterns commit 7c990ad7024035342c4abd6e3fa8feb1b2f2ac2c" diff -r 7995a949189f -r 7954f0d3517f mutational_patterns.R --- a/mutational_patterns.R Thu Oct 22 00:18:38 2020 +0000 +++ b/mutational_patterns.R Thu Oct 22 21:47:48 2020 +0000 @@ -353,7 +353,11 @@ if (!is.na(opt$sig_contrib_matrix)) { output_table <- t(fit_res$contribution)/rowSums(t(fit_res$contribution)) colnames(output_table) <- paste0("s", colnames(output_table)) + if (length(levels(factor(levels_table$level))) > 1) { + output_table <- data.frame(sample=worklist$sample, output_table) + } else { output_table <- data.frame(sample=rownames(output_table), output_table) + } write.table(output_table, file = opt$sig_contrib_matrix, sep = "\t", quote = F, row.names = F) } diff -r 7995a949189f -r 7954f0d3517f mutational_patterns.xml --- a/mutational_patterns.xml Thu Oct 22 00:18:38 2020 +0000 +++ b/mutational_patterns.xml Thu Oct 22 21:47:48 2020 +0000 @@ -1,4 +1,4 @@ - + from genomic variations in vcf files bioconductor-mutationalpatterns diff -r 7995a949189f -r 7954f0d3517f test-data/sig_contrib_table.tsv --- a/test-data/sig_contrib_table.tsv Thu Oct 22 00:18:38 2020 +0000 +++ b/test-data/sig_contrib_table.tsv Thu Oct 22 21:47:48 2020 +0000 @@ -1,5 +1,13 @@ sample s1 s2 s3 s4 s5 s6 s7 s8 s9 s10 s11 s12 s13 s14 s15 s16 s17 s18 s19 s20 s21 s22 s23 s24 s25 s26 s27 s28 s29 s30 -I.vcf 0.110142906240717 0.0107179228940658 0.250337884546217 0 0.123574305205091 0.00064433123164414 0 0.132427942951795 0.0645286099734586 0 0.0449394465051191 0.0482562813691387 0.0021792135773442 0 0.0208527968750023 0.113202769843279 0 0 0 0 0 0 0 0 0.0534957402074307 0 0 0.0246998485796975 0 0 -H.vcf 0.105077406305297 0.0161426031811577 0.213744671485429 0 0.267847442499011 0 0 0.0744758833337775 0.0589788373729043 0 0.0260566297995198 0.00332317088253305 0.0101947253359771 0 0 0.165596602885273 0 0 0 0 0 0 0 0 0.0157724425494898 0 0.0064649564106814 0.0363246279589487 0 0 -G.vcf 0.211033078587086 0.0166966912787851 0.172186940126079 0 0.286633042356631 0 0 0.00842344130070046 0.11400762247453 0 0.0288922172140213 0.0327352792025852 0 0 0 0.034128625357202 0 0 0.0288565039877324 0 0 0 0 0 0.0631355806535697 0 0.000844012191577089 0.00242696526950036 0 0 -F.vcf 0.275881644071761 0.00660164806875313 0.17426347088712 0 0.102714094410494 0 0 0.0917555941611345 0.0202950075653247 0 0.0296908924905143 0.0090315352239272 0 0 0 0.188940992761965 0 0 0 0 0 0 0 0 0.0273695319074987 0 0.00555599996394483 0.0404508145574958 0 0.0274487739300663 +lung - F.vcf 0.110142906240717 0.0107179228940658 0.250337884546217 0 0.123574305205091 0.00064433123164414 0 0.132427942951795 0.0645286099734586 0 0.0449394465051191 0.0482562813691387 0.0021792135773442 0 0.0208527968750023 0.113202769843279 0 0 0 0 0 0 0 0 0.0534957402074307 0 0 0.0246998485796975 0 0 +lung - F.vcf 0.105077406305297 0.0161426031811577 0.213744671485429 0 0.267847442499011 0 0 0.0744758833337775 0.0589788373729043 0 0.0260566297995198 0.00332317088253305 0.0101947253359771 0 0 0.165596602885273 0 0 0 0 0 0 0 0 0.0157724425494898 0 0.0064649564106814 0.0363246279589487 0 0 +lung - F.vcf 0.211033078587086 0.0166966912787851 0.172186940126079 0 0.286633042356631 0 0 0.00842344130070046 0.11400762247453 0 0.0288922172140213 0.0327352792025852 0 0 0 0.034128625357202 0 0 0.0288565039877324 0 0 0 0 0 0.0631355806535697 0 0.000844012191577089 0.00242696526950036 0 0 +lung - G.vcf 0.275881644071761 0.00660164806875313 0.17426347088712 0 0.102714094410494 0 0 0.0917555941611345 0.0202950075653247 0 0.0296908924905143 0.0090315352239272 0 0 0 0.188940992761965 0 0 0 0 0 0 0 0 0.0273695319074987 0 0.00555599996394483 0.0404508145574958 0 0.0274487739300663 +lung - G.vcf 0.110142906240717 0.0107179228940658 0.250337884546217 0 0.123574305205091 0.00064433123164414 0 0.132427942951795 0.0645286099734586 0 0.0449394465051191 0.0482562813691387 0.0021792135773442 0 0.0208527968750023 0.113202769843279 0 0 0 0 0 0 0 0 0.0534957402074307 0 0 0.0246998485796975 0 0 +lung - G.vcf 0.105077406305297 0.0161426031811577 0.213744671485429 0 0.267847442499011 0 0 0.0744758833337775 0.0589788373729043 0 0.0260566297995198 0.00332317088253305 0.0101947253359771 0 0 0.165596602885273 0 0 0 0 0 0 0 0 0.0157724425494898 0 0.0064649564106814 0.0363246279589487 0 0 +ovary - H.vcf 0.211033078587086 0.0166966912787851 0.172186940126079 0 0.286633042356631 0 0 0.00842344130070046 0.11400762247453 0 0.0288922172140213 0.0327352792025852 0 0 0 0.034128625357202 0 0 0.0288565039877324 0 0 0 0 0 0.0631355806535697 0 0.000844012191577089 0.00242696526950036 0 0 +ovary - H.vcf 0.275881644071761 0.00660164806875313 0.17426347088712 0 0.102714094410494 0 0 0.0917555941611345 0.0202950075653247 0 0.0296908924905143 0.0090315352239272 0 0 0 0.188940992761965 0 0 0 0 0 0 0 0 0.0273695319074987 0 0.00555599996394483 0.0404508145574958 0 0.0274487739300663 +ovary - H.vcf 0.110142906240717 0.0107179228940658 0.250337884546217 0 0.123574305205091 0.00064433123164414 0 0.132427942951795 0.0645286099734586 0 0.0449394465051191 0.0482562813691387 0.0021792135773442 0 0.0208527968750023 0.113202769843279 0 0 0 0 0 0 0 0 0.0534957402074307 0 0 0.0246998485796975 0 0 +ovary - I.vcf 0.105077406305297 0.0161426031811577 0.213744671485429 0 0.267847442499011 0 0 0.0744758833337775 0.0589788373729043 0 0.0260566297995198 0.00332317088253305 0.0101947253359771 0 0 0.165596602885273 0 0 0 0 0 0 0 0 0.0157724425494898 0 0.0064649564106814 0.0363246279589487 0 0 +ovary - I.vcf 0.211033078587086 0.0166966912787851 0.172186940126079 0 0.286633042356631 0 0 0.00842344130070046 0.11400762247453 0 0.0288922172140213 0.0327352792025852 0 0 0 0.034128625357202 0 0 0.0288565039877324 0 0 0 0 0 0.0631355806535697 0 0.000844012191577089 0.00242696526950036 0 0 +ovary - I.vcf 0.275881644071761 0.00660164806875313 0.17426347088712 0 0.102714094410494 0 0 0.0917555941611345 0.0202950075653247 0 0.0296908924905143 0.0090315352239272 0 0 0 0.188940992761965 0 0 0 0 0 0 0 0 0.0273695319074987 0 0.00555599996394483 0.0404508145574958 0 0.0274487739300663