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?
Is it not an option just to add the path to write sam and summary files on fastq files directory (or anywhere you want)?
That worked! Thank you. Didn't know that was an option... now I know.
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 showsPathway of my reference genome
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
I thought this was like bowtie2 where you need to specify the base file prefix as well. So, if your directory looks like:
Then you would specify
yes correct you have to pass the full prefix and not the directory