Skip to content

Commit

Permalink
adapted output format
Browse files Browse the repository at this point in the history
  • Loading branch information
JohannesGawron committed Jun 26, 2024
1 parent bd88857 commit 7729df5
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 8 deletions.
2 changes: 0 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@ repos:
rev: v0.4.2
hooks:
- id: style-files
args: [--warn_only]
- id: parsable-R
args: [--warn-only]
- id: lintr
args: [--warn_only]
verbose: true
Expand Down
4 changes: 2 additions & 2 deletions experiments/config/config.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#sample: ['Lu2']
sample: ['Br11', 'Br7', 'Br61', 'Br38', 'LM2', 'Pr9', 'Br23','Br39', 'Br57', 'Lu2', 'Br16_AC', 'Br16_B', 'Br16_C', 'Br26', 'Br44', 'Lu7', 'Br30', 'Br45', 'Ov8', 'Br37', 'Br46', 'Brx50', 'Pr6']
sample: ['Br11']
#sample: ['Br11', 'Br7', 'Br61', 'Br38', 'LM2', 'Pr9', 'Br23','Br39', 'Br57', 'Lu2', 'Br16_AC', 'Br16_B', 'Br16_C', 'Br26', 'Br44', 'Lu7', 'Br30', 'Br45', 'Ov8', 'Br37', 'Br46', 'Brx50', 'Pr6']
author: Johannes Gawron
input: /cluster/work/bewi/members/jgawron/projects/CTC/input_folder
simulations: /cluster/work/bewi/members/jgawron/projects/CTC/simulations/simulations2
4 changes: 3 additions & 1 deletion experiments/workflow/Snakefile
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ include: "rules/base.smk"

all_files = []
for sample in SAMPLES:
all_files.append((PROJECT_DIR / "data" / "htmls" / f"{sample}.html").resolve())
all_files.append(
(PROJECT_DIR / "data" / "htmls" / f"{sample}_treeSampling.html").resolve()
)
all_files.append(
(PROJECT_DIR / "data" / "htmls" / f"{sample}_topSeparators.html").resolve()
)
Expand Down
3 changes: 2 additions & 1 deletion experiments/workflow/resources/template.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ simulationInputFolder <- params$simulationInputFolder
treeName <- params$treeName
nTreeSamplingEvents <- params$nSamplingEvents
nMutationSamplingEvents <- params$nSamplingEvents
nSamplingEvents <- params$nSamplingEvents
```

## Loading data
Expand Down Expand Up @@ -155,7 +156,7 @@ for (clusterSize in 2:5) {
nOligoclonalClusters2 <- nOligoclonalClusters2 + 1
oligoclonal <- TRUE
}
splittingSummary2 <- rbind(splittingSummary2, data.frame(Color = color, Oligoclonal = oligoclonal, ClusterSize = clusterSize))
splittingSummary2 <- rbind(splittingSummary2, data.frame(Color = color, Oligoclonal = oligoclonal, ClusterSize = clusterSize, cutoff = cutoffsBranchingProbabilities[(cutoffsBranchingProbabilities$clusterSize == clusterSize), 2], mean_splitting_score = branchingProbs))
}
})
}
Expand Down
4 changes: 2 additions & 2 deletions experiments/workflow/rules/base.smk
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ rule render_markdown_file:
input_dir=INPUT_FOLDER,
simulation_dir=SIMULATION_FOLDER,
resources:
mem_mb=2048,
mem_mb_per_cpu=4096,
runtime=2880,
threads: 16
conda:
Expand All @@ -88,7 +88,7 @@ rule render_markdown_file:
PROJECT_DIR / "logs" / "render_markdown_file.{SAMPLE}.log",
shell:
"""
( Rscript -e "rmarkdown::render('{input}', output_file = '{output}')", params = list(inputFolder = {params.input_dir}, nSamplingEvents = {params.sampling_depth}, simulationInputFolder = {params.simulation_dir}, treeName = {wildcard.SAMPLE}, functionsScript = {params.script_dir}) ) &> {log}
( Rscript -e "rmarkdown::render('{input}', output_file = '{output}', params = list(inputFolder = '{params.input_dir}', nSamplingEvents={params.sampling_depth}, simulationInputFolder = '{params.simulation_dir}', treeName = '{wildcards.SAMPLE}', functionsScript = '{params.script_dir}'))" ) &> {log}
"""


Expand Down

0 comments on commit 7729df5

Please sign in to comment.