Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
RMI2 pipelines
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
Model registry
Operate
Environments
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
LBMC
RMI2
RMI2 pipelines
Commits
dfc75475
Commit
dfc75475
authored
4 years ago
by
elabaron
Browse files
Options
Downloads
Patches
Plain Diff
src/RibosomeProfiling.nf : discard reverse alignments in postgenome alignement
parent
82ac6ea3
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/RibosomeProfiling.nf
+4
-4
4 additions, 4 deletions
src/RibosomeProfiling.nf
with
4 additions
and
4 deletions
src/RibosomeProfiling.nf
+
4
−
4
View file @
dfc75475
...
@@ -472,7 +472,7 @@ hisat2 -x ${index2_id} \
...
@@ -472,7 +472,7 @@ hisat2 -x ${index2_id} \
--trim3 1 \
--trim3 1 \
--trim5 1 \
--trim5 1 \
2> ${file_id}_postgenome.txt \
2> ${file_id}_postgenome.txt \
| samtools view -bS -F 4 -F 256 - \
| samtools view -bS -F 4 -F 256
-F 16
- \
| samtools sort -@ ${task.cpus} -o ${file_id}_postgenome.bam \
| samtools sort -@ ${task.cpus} -o ${file_id}_postgenome.bam \
&& samtools index ${file_id}_postgenome.bam
&& samtools index ${file_id}_postgenome.bam
...
@@ -504,7 +504,7 @@ if (params.do_dedup){
...
@@ -504,7 +504,7 @@ if (params.do_dedup){
when:
when:
params
.
do_dedup
params
.
do_dedup
shell:
shell:
'''
'''
samtools view -h !{bam[0]} | awk '!seen[substr($1, length($1)-5) $3 $4 $10]++' | samtools view -bS -o !{file_id}_dedup.bam
samtools view -h !{bam[0]} | awk '!seen[substr($1, length($1)-5) $3 $4 $10]++' | samtools view -bS -o !{file_id}_dedup.bam
...
@@ -594,7 +594,7 @@ if (params.do_postgenome){
...
@@ -594,7 +594,7 @@ if (params.do_postgenome){
echo "total counts : $total" >> !{file_id}.txt
echo "total counts : $total" >> !{file_id}.txt
echo "scaling factor : !{factor}" >> !{file_id}.txt
echo "scaling factor : !{factor}" >> !{file_id}.txt
if [ !{genome} -gt 0 ]
if [ !{genome} -gt 0 ]
then
then
bamCoverage -p !{task.cpus} --binSize 1 --scaleFactor !{factor} -b !{genome_bam[0]} -o !{file_id}_genome.bigwig
bamCoverage -p !{task.cpus} --binSize 1 --scaleFactor !{factor} -b !{genome_bam[0]} -o !{file_id}_genome.bigwig
fi
fi
if [ !{postgenome} -gt 0 ]
if [ !{postgenome} -gt 0 ]
...
@@ -642,7 +642,7 @@ if (params.do_postgenome){
...
@@ -642,7 +642,7 @@ if (params.do_postgenome){
echo "genome aligment : !{genome} counts" >> !{file_id}.txt
echo "genome aligment : !{genome} counts" >> !{file_id}.txt
echo "scaling factor : !{factor}" >> !{file_id}.txt
echo "scaling factor : !{factor}" >> !{file_id}.txt
if [ !{genome} -gt 0 ]
if [ !{genome} -gt 0 ]
then
then
bamCoverage -p !{task.cpus} --binSize 1 --scaleFactor !{factor} -b !{genome_bam[0]} -o !{file_id}_genome.bigwig
bamCoverage -p !{task.cpus} --binSize 1 --scaleFactor !{factor} -b !{genome_bam[0]} -o !{file_id}_genome.bigwig
fi
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