Skip to content
Snippets Groups Projects
Commit 4845e672 authored by Tobias Marschall's avatar Tobias Marschall
Browse files

Avoid re-installing MaRyam each time a heatmap is plotted and properly redirect output to log file.

parent 04ad1d2a
No related branches found
No related tags found
No related merge requests found
...@@ -383,12 +383,15 @@ rule run_sv_classification: ...@@ -383,12 +383,15 @@ rule run_sv_classification:
rule plot_heatmap: rule plot_heatmap:
input: input:
maryam = "utils/R-packages2/MaRyam/R/MaRyam",
haplotypeProbs = "sv_probabilities/{sample}/{windows}.{bpdens}/allSegCellProbs.table", haplotypeProbs = "sv_probabilities/{sample}/{windows}.{bpdens}/allSegCellProbs.table",
genotypeProbs = "sv_probabilities/{sample}/{windows}.{bpdens}/allSegCellGTprobs.table", genotypeProbs = "sv_probabilities/{sample}/{windows}.{bpdens}/allSegCellGTprobs.table",
info = "counts/{sample}/{windows}.info", info = "counts/{sample}/{windows}.info",
bamNames = "sv_probabilities/{sample}/{windows}.{bpdens}/bamNames.txt" bamNames = "sv_probabilities/{sample}/{windows}.{bpdens}/bamNames.txt"
output: output:
"sv_probabilities/{sample}/{windows}.{bpdens}/final_plots/heatmapPlots.pdf" "sv_probabilities/{sample}/{windows}.{bpdens}/final_plots/heatmapPlots.pdf"
params:
r_package_path = "utils/R-packages2"
log: log:
"log/{sample}/final.plots.{windows}.{bpdens}.txt" "log/{sample}/final.plots.{windows}.{bpdens}.txt"
script: script:
......
#' Rscript for the snakemake pipeline for computing jump probabilities and including heatmaps #' Rscript for the snakemake pipeline for computing jump probabilities and including heatmaps
#' author Maryam Ghareghani #' author Maryam Ghareghani
# install and load MaRyam package sink(snakemake@log[[1]])
library(devtools)
install_git("git://github.com/friendsofstrandseq/MaRyam.git", branch = "master")
library("MaRyam")
.libPaths( c( snakemake@params[["r_package_path"]],.libPaths()) )
suppressPackageStartupMessages(library(MaRyam))
hapProbsFile = snakemake@input[["haplotypeProbs"]] hapProbsFile = snakemake@input[["haplotypeProbs"]]
GTprobsFile = snakemake@input[["genotypeProbs"]] GTprobsFile = snakemake@input[["genotypeProbs"]]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment