how to run a tool (package) installed into anaconda environment ..using mac terminal
1
3
Entering edit mode
3.9 years ago
Pegasus ▴ 100

Hi all,

I built an environment in Anaconda..and installed a Trimmomatic package... how to launch the Trimmomatic tool using Mac terminal.. and apply the tool on fastaq file located in my local server!

genome • 5.6k views
ADD COMMENT
2
Entering edit mode

I mean how to launch the Trimmomatic tool using Mac terminal.

There is no graphical interface to launch, if that is what you are expecting.

ADD REPLY
0
Entering edit mode

Actually I meant to start the tool..what command or code should I write in the terminal, after activating the environment

ADD REPLY
0
Entering edit mode

You can simply go into the bin folder of your anaconda and check how exactly the tool is named.

ADD REPLY
1
Entering edit mode

Have you activated the environment? Did you try to run it following the manual?

ADD REPLY
0
Entering edit mode

Thanks for your answer, yes I activated the environment using the code " conda activate py2" and confirmed that the Trimmomatic is presented in Py2 environment by using the code "conda list", but whats next ...how to run Trimmomatic!

ADD REPLY
0
Entering edit mode

According to the manual, for single end mode; java -classpath <path to="" trimmomatic="" jar=""> org.usadellab.trimmomatic.TrimmomaticSE [- threads <threads>] [-phred33 | -phred64] [-trimlog <logfile>] <input> <output> <step 1=""> ...

Should I flow the same process even I used installation code to install Trmmomatic package, not downloaded a jar file!!

ADD REPLY
3
Entering edit mode

After installation with conda you should just run trimmomatic rather than java -jar etc

ADD REPLY
0
Entering edit mode

ok, but what is the command (code to run) ..I followed these steps;

In terminal;

activate py3 #(which is my anaconda environment that contains trimmomatic)

after activation;

I tried;

trimmomatic 
open trimmomatic

but no code could run the tool!!!

ADD REPLY
0
Entering edit mode

but no code could run the tool!!!

What does that mean? Which error message did you get? You will have to be more specific if you expect help. What is the output of conda list?

ADD REPLY
0
Entering edit mode

Hi, sorry for being unspecific ...Trimmomatic is shown in the conda list output, which confirmed that I have Trimmomatic in my environment.

run Trimmomatic showed me this output;

Usage: 
       PE [-version] [-threads <threads>] [-phred33|-phred64] [-trimlog <trimLogFile>] [-summary <statsSummaryFile>] [-quiet] [-validatePairs] [-basein <inputBase> | <inputFile1> <inputFile2>] [-baseout <outputBase> | <outputFile1P> <outputFile1U> <outputFile2P> <outputFile2U>] <trimmer1>...
   or: 
       SE [-version] [-threads <threads>] [-phred33|-phred64] [-trimlog <trimLogFile>] [-summary <statsSummaryFile>] [-quiet] <inputFile> <outputFile> <trimmer1>...

So I think I need to go through the trimmomatic guide to more understand these terms.

Thanks

ADD REPLY
3
Entering edit mode

What you are looking at is in-line help that trimmomatic provides. It is giving you a clue as to what you minimally need in your command line. Generally things in <> are optional. Here is an example of what a real command looks like:

trimmomatic PE -threads 4 SRR_1056_1.fastq SRR_1056_2.fastq  \
              SRR_1056_1.trimmed.fastq SRR_1056_1un.trimmed.fastq \
              SRR_1056_2.trimmed.fastq SRR_1056_2un.trimmed.fastq \
              ILLUMINACLIP:adapters.fa SLIDINGWINDOW:4:20

\ in command line is used to wrap the command on multiple lines. That is not necessary when you type the command out. This example is for paired-end data. If you have single-end reads then things would change some.

trimmomatic SE -threads 4 SRR_1056.fastq \
              SRR_1056.trimmed.fastq SRR_1056_un.trimmed.fastq \
              ILLUMINACLIP:SRR_adapters.fa SLIDINGWINDOW:4:20
ADD REPLY
0
Entering edit mode

thanks for your explanation

ADD REPLY
0
Entering edit mode

Hi genomax,

I activated my python-based environment in mac terminal. And using the Trimmomatic code:

trimmomatic PE -threads 4 SRR_292770_1.fastq SRR_292770_2.fastq \ SRR_292770_1.trimmed.fastq SRR_292770_1un.trimmed.fastq \ SRR_292770_2.trimmed.fastq SRR_292770_2un.trimmed.fastq \ ILLUMINACLIP:adapters.fa SLIDINGWINDOW:4:20

showed me this error; ^ SyntaxError: invalid syntax

I wonder where is the problem!!

ADD REPLY
1
Entering edit mode

Make sure you are using proper hypens and underscores. macOS has something called smartquotes and dashes. Turn them off under System pref -> Keyboard -> text and then re-type the command and see if that helps. Your command looks good otherwise.

ADD REPLY
2
Entering edit mode

So I think I need to go through the trimmomatic guide to more understand these terms.

Yes, that's usually the best idea to start there before diving in trying out a new tool.

ADD REPLY
1
Entering edit mode
3.9 years ago

After installation with conda the executable is named trimmomatic.

ADD COMMENT

Login before adding your answer.

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