Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
ChIPster
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Xavier Grand
ChIPster
Commits
0d885dcd
Verified
Commit
0d885dcd
authored
4 years ago
by
Laurent Modolo
Browse files
Options
Downloads
Patches
Plain Diff
macs3: add main.nf
parent
88b0ccc4
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/nf_modules/macs3/main.nf
+69
-0
69 additions, 0 deletions
src/nf_modules/macs3/main.nf
with
69 additions
and
0 deletions
src/nf_modules/macs3/main.nf
0 → 100644
+
69
−
0
View file @
0d885dcd
version = "3.0.0a6"
container_url = "lbmc/macs3:${version}"
process peak_calling {
container = "${container_url}"
label "big_mem_multi_cpus"
tag "${file_id}"
input:
tuple val(file_id), path(bam_ip), path(bam_control)
output:
path "*", emit: peak
path "*_report.txt", emit: report
script:
/* remove --nomodel option for real dataset */
"""
macs2 callpeak \
--treatment ${file_ip} \
--call-summits "True"\
--control ${file_control} \
--keep-dup "auto" \
--name ${bam_ip.simpleName} \
--gsize ${macs3_genome_size} 2> \
${bam_ip.simpleName}_macs3_report.txt
if grep -q "ERROR" ${bam_ip.simpleName}_macs3_report.txt; then
echo "MACS3 error"
exit 1
fi
"""
}
process peak_calling_bg {
container = "${container_url}"
label "big_mem_multi_cpus"
tag "${file_id}"
input:
tuple val(file_id), path(bg_ip), path(bg_control)
output:
path "*", emit: peak
path "*_report.txt", emit: report
script:
/* remove --nomodel option for real dataset */
"""
awk '{print $1"\t"$2"\t"$3"\t.\t+\t"$4}' ${file_ip} > \
${file_ip.simpleName}.bed
awk '{print $1"\t"$2"\t"$3"\t.\t+\t"$4}' ${file_control} > \
${file_control.simpleName}.bed
macs2 callpeak \
--treatment ${file_ip.simpleName}.bed \
--call-summits "True"\
--control ${file_control.simpleName}.bed \
--keep-dup "auto" \
--name ${bam_ip.simpleName} \
--gsize ${macs3_genome_size} 2> \
${bam_ip.simpleName}_macs3_report.txt
if grep -q "ERROR" ${bam_ip.simpleName}_macs3_report.txt; then
echo "MACS3 error"
exit 1
fi
"""
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment