Skip to content
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

Allowing to use a genome not in igenomes #63

Closed
wants to merge 3 commits into from
Closed
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ if (!params.references_parsed && !params.skip_mirdeep){
file hairpin from reference_hairpin

output:
file 'genome.fa' into fasta
//file 'genome.fa' into fasta
ewels marked this conversation as resolved.
Show resolved Hide resolved
file 'genome.*.ebwt' into indices_mirdeep2
file 'hairpin.fa' into hairpin
file 'mature.fa' into mature
Expand All @@ -318,11 +318,11 @@ if (!params.references_parsed && !params.skip_mirdeep){
HAIRPIN="$hairpin"
if [ \${MATURE: -3} == ".gz" ]; then
gunzip -f \$MATURE
MATURE=\${MATURE: -3}
MATURE=\${MATURE%%.gz}
fi
if [ \${HAIRPIN: -3} == ".gz" ]; then
gunzip -f \$HAIRPIN
HAIRPIN=\${HAIRPIN: -3}
HAIRPIN=\${HAIRPIN%%.gz}
fi

# Remove any special base characters from reference genome FASTA file
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the line below should be:
sed '/^[^>]/s/[^ATGCatgc]/N/g' $refgenome > genome.fa

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and update below to bowtie-build genome.fa genome

Expand Down Expand Up @@ -827,7 +827,7 @@ process mirdeep2 {
!params.skip_mirdeep

input:
file refgenome from fasta
file refgenome from reference_genome
ewels marked this conversation as resolved.
Show resolved Hide resolved
file reads_collapsed from mirdeep_reads_collapsed
file reads_vs_refdb from reads_vs_refdb
file mature from mature
Expand All @@ -839,15 +839,16 @@ process mirdeep2 {


script:

"""
perl -ane 's/y/N/ig;print;' $hairpin > hairpin_yn.fa

miRDeep2.pl \\
$reads_collapsed \\
$refgenome \\
$reads_vs_refdb \\
$mature \\
none \\
$hairpin \\
hairpin_yn.fa \\
-d \\
-z _${reads_collapsed.simpleName}
"""
Expand Down