Question: TopHat installation error
0
gravatar for salamandra
3.4 years ago by
salamandra330
salamandra330 wrote:

I'm new to ubuntu and i am trying to install tophat-2.1.1.Linux_x86_64 in an ubuntu 16.04 LTS system.

I unpacked the binary version to the home directory, and because ~/bin is in my $PATH I did:

cd 
tar xvfz tophat-2.1.1.Linux_x86_64.tar.gz
cd ~/bin
ln -s ~/tophat-2.1.1.Linux_x86_64/tophat2

And I got the following error when type tophat2:

File "/home/tania/tophat-2.1.1.Linux_x86_64/tophat", line 1003
    except getopt.error, msg:
                       ^
SyntaxError: invalid syntax

What am I doing wrong?

tophat • 3.0k views
ADD COMMENTlink modified 2.7 years ago by Bilal50 • written 3.4 years ago by salamandra330

Try tophat2 -h. (or -help) It is expecting you to provide some input.

ADD REPLYlink modified 3.4 years ago • written 3.4 years ago by genomax89k

it gives the same error

ADD REPLYlink written 3.4 years ago by salamandra330

The investigate @Wouter's suggestion below.

ADD REPLYlink written 3.4 years ago by genomax89k

Looks like a wrong python version issue

ADD REPLYlink written 3.4 years ago by WouterDeCoster44k

to use tophat Python version 2.6 or higher is required, and mine is Python 3.5.2, so it isn't cause of that

ADD REPLYlink written 3.4 years ago by salamandra330
1

See http://seqanswers.com/forums/showthread.php?t=17514

ADD REPLYlink written 3.4 years ago by WouterDeCoster44k

Oh and stop using tophat for new projects, it's deprecated

ADD REPLYlink written 3.4 years ago by WouterDeCoster44k
4
gravatar for Devon Ryan
3.4 years ago by
Devon Ryan96k
Freiburg, Germany
Devon Ryan96k wrote:

You're using python3, which won't work for tophat2 (or bowtie2). Anyway, there's no reason to ever use tophat2 for new analyses. Use STAR or BBmap.

ADD COMMENTlink written 3.4 years ago by Devon Ryan96k

.toggled status to accepted.

ADD REPLYlink written 3.4 years ago by WouterDeCoster44k
4
gravatar for Bilal
2.7 years ago by
Bilal50
Bilal50 wrote:

edit the first line in your_tophat_directory/tophat from:

#!/usr/bin/env python

to:

#!/usr/bin/env python2

It worked for me.

ADD COMMENTlink written 2.7 years ago by Bilal50

Thanks, this worked for me. I know tophat hasn't been updated since 2016, but some pipelines still use it.

ADD REPLYlink written 12 months ago by alex.v.nesta30

This works for me...thanks

ADD REPLYlink written 4 months ago by javanokendo0
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 485 users visited in the last hour