Hisat2 index and alignment question
0
0
Entering edit mode
14 months ago
Athena • 0

I indexed my reference genome using hisat2-build (mus musculus) and got 8 index files. However when I tried to start my alignment in the directory of my fastq files using this command

hisat2 -p 8 -x /path/to/musculus_index -1 SRR8348941_1_P.fastq.gz -2 SRR8348941_2_P.fastq.gz -S SRR8348941.sam --dta-cufflinks 2>&1 |tee SRR8348941.summary

it won't run but when I run the command in the directory my index files are located

hisat2 -p 8 -x musculus_index -1 /path/to/SRR8348941_1_P.fastq.gz -2 /path/to/SRR8348941_2_P.fastq.gz -S SRR8348941.sam --dta-cufflinks 2>&1 |tee SRR8348941.summary

it will generate the output files. Is there a reason why the first method (running the alignment command in the fastq file directory) does not work? How can I run the alignment command in the fastq file directory rather than in the index directory to generate output files?

ubuntu rna-seq index hisat2 • 1.2k views
ADD COMMENT
1
Entering edit mode

Is it not an option just to add the path to write sam and summary files on fastq files directory (or anywhere you want)?

hisat2 -p 8 -x musculus_index -1 /path/to/SRR8348941_1_P.fastq.gz -2 /path/to/SRR8348941_2_P.fastq.gz -S **/path/to/**SRR8348941.sam --dta-cufflinks 2>&1 |tee **/path/to/**SRR8348941.summary
ADD REPLY
0
Entering edit mode

That worked! Thank you. Didn't know that was an option... now I know.

ADD REPLY
1
Entering edit mode

the most logical and simple explanation is that most likely the path to index is specified incorrectly

show us the paths with say ls then the way you invoke the command and the error it shows

ADD REPLY
0
Entering edit mode

Pathway of my reference genome reference index pathway

when I tried running this command

hisat2 -p 8 -x /path/to/musculus_index -1 SRR8348941_1_P.fastq.gz -2 SRR8348941_2_P.fastq.gz -S SRR8348941.sam --dta-cufflinks 2>&1 |tee SRR8348941.summary

in the directory where my fastq files are located, I got the error message (pic below) that it doesn't exist

Error message

ADD REPLY
1
Entering edit mode

I thought this was like bowtie2 where you need to specify the base file prefix as well. So, if your directory looks like:

/path/to/musculus_index/musculus_index.1.ht2
/path/to/musculus_index/musculus_index.2.ht2
/path/to/musculus_index/musculus_index.3.ht2
...

Then you would specify

/path/to/musculus_index/musculus_index
ADD REPLY
1
Entering edit mode

yes correct you have to pass the full prefix and not the directory

ADD REPLY

Login before adding your answer.

Traffic: 2888 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6