salmon command not found from shell
1
0
Entering edit mode
3.4 years ago

Hi all, I'm using Salmon to align fastq files to an index genome and I've installed all associated packages (as far as I know). When I call salmon from the terminal, everything runs fine. I previously used a shell script to automate alignment for multiple files, but I suddenly get the error messages "salmon: command not found" and "gzip: command not found".

The command I use in terminal (single files) is:

salmon quant -i human_index --libType A -r /Rprojects/Sweet_et_al/fastq/SRR7426123.fastq -o /Rprojects/Sweet_et_al/quant/SRR7426123

The shell script I use looks like this:

#!/bin/bash
PATH="/media/manager/HDD_Martijn/RNAseq"
for i in {123..130}
do
salmon quant -i ${PATH}/salmon/human_index --libType A -r ${PATH}/Rprojects/Sweet_et_al/fastq/SRR7426${i}.fastq -o ${PATH}/Rprojects/Sweet_et_al/quant/SRR7426${i}
gzip ${PATH}/Rprojects/Sweet_et_al/quant/SRR7426${i}/quant.sf
done

It used to work just fine, but I haven't used it in a while. Something is wrong and I'm not very familiar with Linux. Can anyone help me figure this out? Any and all suggestions would be greatly appreciated! Thank you.

alignment RNA-Seq • 1.1k views
ADD COMMENT
6
Entering edit mode
3.4 years ago

You should not use PATH as a variable, as you are overwriting the $PATH environmental variable which tells your shell where to find executables (such as gzip and salmon)

ADD COMMENT
0
Entering edit mode

Hi Wouter, this is great! Thanks for your help. That fixed it I wasn't aware that I was overwriting the PATH variable.

ADD REPLY

Login before adding your answer.

Traffic: 3198 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