generated from CCBR/CCBR_NextflowTemplate
-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improvements to chipseeker, contrast & input checks, docs #192
Merged
Changes from 11 commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
49eb54c
fix #191
slsevilla 39fe6af
fix: #186
slsevilla 4c5e96e
fix: iss#185
slsevilla 1193c40
fix: increase cpu allocation iss#183
slsevilla d1ce47a
feat: check contrast manifest during inputcheck fix iss#181
slsevilla 123057b
chore: fix errors in def location, add comments to list
slsevilla a21c8af
docs: adding start of manifest docs iss#174
slsevilla 40e067c
chore: correct input variables for contrast
slsevilla ff770fd
docs: add workflow info
slsevilla 0d8dc36
fix: increase memory #195
slsevilla 105dd26
fix: separates contrast and contrastsheet params #196
slsevilla 7fa12f2
docs: add todo to docs/workflow.md
kelly-sovacool 3846a5e
docs: add TODO to docs/manifests.md
kelly-sovacool File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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,30 @@ | ||
# Jotting notes here | ||
kelly-sovacool marked this conversation as resolved.
Show resolved
Hide resolved
|
||
## Samplemanifest | ||
The following columns are required: | ||
|
||
- sample: sampleID; does not need to be a unique column | ||
- rep: replicateID of sampleID; does not need to be a unique column | ||
- fastq_1: absolute path to R1 of sampleID | ||
- fastq_2: absolute path to R1 of sampleID | ||
- antibody: -c sampleID for mac2; this must match a unique {sample}_{rep} format | ||
- control: | ||
|
||
Example antibody / control format for a single-end project: | ||
|
||
``` | ||
sample,rep,fastq_1,fastq_2,antibody,control | ||
sample,1,/path/to/sample_1.R1.fastq.gz,,input_1,input_1 | ||
sample,2,/path/to/sample_2.R1.fastq.gz,,input_1,input_1 | ||
input,1,/path/to/sample1.R1.fastq.gz,,, | ||
input,2,/path/to/sample1.R1.fastq.gz,,, | ||
``` | ||
|
||
Example antibody / control format for a paired-end project: | ||
|
||
``` | ||
sample,rep,fastq_1,fastq_2,antibody,control | ||
sample,1,/path/to/sample_1.R1.fastq.gz,/path/to/sample_1.R2.fastq.gz,input_1,input_1 | ||
sample,2,/path/to/sample_2.R1.fastq.gz,/path/to/sample_1.R2.fastq.gz,input_1,input_1 | ||
input,1,/path/to/input_1.R1.fastq.gz,/path/to/input_1.R2.fastq.gz,, | ||
input,2,/path/to/input_2.R1.fastq.gz,/path/to/input_2.R2.fastq.gz,, | ||
``` |
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,131 @@ | ||
## Process workflow | ||
|
||
Will need to add images to show workflow | ||
kelly-sovacool marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
### Pipeline Checks | ||
- Input files are checked that they meet standard formatting; some file access is reviewed | ||
|
||
- Processes include: | ||
|
||
- INPUT_CHECK:SAMPLESHEET_CHECK | ||
- INPUT_CHECK:CHECK_CONTRASTS | ||
|
||
- Output directories include: | ||
|
||
- check_contrasts | ||
|
||
## Pre-alignment | ||
- Adaptors are trimmed, if blacklists are included, filtering occurs | ||
|
||
- Processes include: | ||
|
||
- CUTADAPT | ||
- FILTER_BLACKLIST:BWA_MEM | ||
- FILTER_BLACKLIST:SAMTOOLS_FILTERALIGNED | ||
- FILTER_BLACKLIST:PICARD_SAMTOFASTQ | ||
- FILTER_BLACKLIST:CUSTOM_COUNTFASTQ | ||
|
||
- Output directories include: | ||
|
||
- cutadapt | ||
|
||
## Alignment | ||
- Samples are aligned using BWA; alignment stats are generated; samples are sorted and filtered | ||
|
||
- Processes include: | ||
|
||
- ALIGN_GENOME:BWA_MEM | ||
- ALIGN_GENOME:SAMTOOLS_FLAGSTAT_ALIGN | ||
- ALIGN_GENOME:FILTER_QUALITY | ||
- ALIGN_GENOME:SAMTOOLS_SORT | ||
- ALIGN_GENOME:SAMTOOLS_FLAGSTAT_FILTER | ||
|
||
- Output directories include: | ||
|
||
- bwa_mem | ||
- samtools_flagstat_align | ||
- samtools_filteraligned | ||
- samtools_sort | ||
- samtools_flagstat_filter | ||
|
||
## Deduplicate | ||
- Processes include: | ||
|
||
- DEDUPLICATE:MACS2_DEDUP | ||
- DEDUPLICATE:INDEX_SINGLE | ||
- DEDUPLICATE:PICARD_DEDUP | ||
- DEDUPLICATE:INDEX_PAIRED | ||
|
||
- Output directories include: | ||
|
||
## Quality Control | ||
- Processes include: | ||
|
||
- PPQT_PROCESS | ||
- QC:FASTQC_RAW | ||
- QC:FASTQC_TRIMMED | ||
- QC:FASTQ_SCREE | ||
- QC:PRESEQ | ||
- QC:HANDLE_PRESEQ_ERROR | ||
- QC:PARSE_PRESEQ_LOG | ||
- QC:QC_STATS | ||
- QC:QC_TABLE | ||
|
||
## Deeptools analysis | ||
- Processes include: | ||
|
||
- QC:DEEPTOOLS:BAM_COVERAGE | ||
- QC:DEEPTOOLS:BIGWIG_SUM | ||
- QC:DEEPTOOLS:PLOT_CORRELATION | ||
- QC:DEEPTOOLS:PLOT_PCA | ||
- QC:DEEPTOOLS:NORMALIZE_INPUT | ||
- QC:DEEPTOOLS:BED_PROTEIN_CODING | ||
- QC:DEEPTOOLS:COMPUTE_MATRIX | ||
- QC:DEEPTOOLS:PLOT_HEATMAP | ||
- QC:DEEPTOOLS:PLOT_PROFILE | ||
- QC:DEEPTOOLS:PLOT_FINGERPRINT | ||
|
||
## Peak calling | ||
- Processes include: | ||
|
||
- PHANTOM_PEAKS | ||
- CALL_PEAKS:CALC_GENOME_FRAC | ||
- CALL_PEAKS:BAM_TO_BED | ||
- CALL_PEAKS:MACS_BROAD | ||
- CALL_PEAKS:MACS_NARROW | ||
- CALL_PEAKS:SICER | ||
- CALL_PEAKS:CONVERT_SICER | ||
- CALL_PEAKS:GEM | ||
- CALL_PEAKS:FILTER_GEM | ||
- CALL_PEAKS:FRACTION_IN_PEAKS | ||
- CALL_PEAKS:CONCAT_FRIPS | ||
- CALL_PEAKS:PLOT_FRIP | ||
- CALL_PEAKS:GET_PEAK_META | ||
- CALL_PEAKS:CONCAT_PEAK_META | ||
- CALL_PEAKS:PLOT_PEAK_WIDTHS | ||
|
||
## Consensus Peaks | ||
- Processes include: | ||
|
||
- CONSENSUS_PEAKS:CAT_CAT | ||
- CONSENSUS_PEAKS:SORT_BED | ||
- CONSENSUS_PEAKS:BEDTOOLS_MERGE | ||
- CONSENSUS_PEAKS:- CONSENSUS_PEAKS:_OUT | ||
|
||
## Annotate | ||
- Processes include: | ||
|
||
- ANNOTATE:CHIPSEEKER_PEAKPLOT | ||
- ANNOTATE:CHIPSEEKER_ANNOTATE | ||
- ANNOTATE:CHIPSEEKER_PLOTLIST | ||
- ANNOTATE:HOMER_MOTIFS | ||
- ANNOTATE:MEME_AME | ||
|
||
## Differential Analysis | ||
- If there are more than 2 replicates per group then `diffbind` is performed; otherwise `manorm` pairewise analysis is performed | ||
|
||
- Processes include: | ||
|
||
- DIFF:DIFFBIND:PREP_DIFFBIND | ||
- DIFF:DIFFBIND:DIFFBIND_RMD | ||
- DIFF:MANORM:MANORM_PAIRWISE |
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 | ||||
---|---|---|---|---|---|---|
|
@@ -36,6 +36,9 @@ include { PHANTOM_PEAKS | |||||
PPQT_PROCESS | ||||||
MULTIQC } from "./modules/local/qc.nf" | ||||||
|
||||||
|
||||||
contrastsheet = params.contrastsheet ?: "/assets/contrast_test.ymls" | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should this be
Suggested change
to make sure it uses the project directory as root, instead of the root of the file system? |
||||||
|
||||||
workflow.onComplete { | ||||||
if (!workflow.stubRun && !workflow.commandLine.contains('-preview')) { | ||||||
def message = Utils.spooker(workflow) | ||||||
|
@@ -64,7 +67,7 @@ workflow { | |||||
} | ||||||
|
||||||
workflow CHIPSEQ { | ||||||
INPUT_CHECK(file(params.input, checkIfExists: true), params.seq_center) | ||||||
INPUT_CHECK(file(params.input, checkIfExists: true), params.seq_center, file(contrastsheet)) | ||||||
|
||||||
INPUT_CHECK.out.reads.set { raw_fastqs } | ||||||
raw_fastqs | CUTADAPT | ||||||
|
@@ -129,7 +132,6 @@ workflow CHIPSEQ { | |||||
} | ||||||
.set{ ch_consensus_peaks } | ||||||
if (params.contrasts) { | ||||||
contrasts = file(params.contrasts, checkIfExists: true) | ||||||
// TODO use consensus peaks for regions of interest in diffbind | ||||||
CALL_PEAKS.out.bam_peaks | ||||||
.combine(deduped_bam) | ||||||
|
@@ -145,8 +147,7 @@ workflow CHIPSEQ { | |||||
.set{ tagalign_peaks } | ||||||
DIFF( bam_peaks, | ||||||
tagalign_peaks, | ||||||
INPUT_CHECK.out.csv, | ||||||
contrasts | ||||||
INPUT_CHECK.out.contrasts | ||||||
) | ||||||
|
||||||
} | ||||||
|
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
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.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are boolean values supposed to be quoted in nextflow?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we don't need
contrasts
in the config files now thatmain.nf
checks forcontrastsheet
, right?