Entering edit mode
8.0 years ago
Lila M
★
1.3k
Hi, I'm trying to install macs2. After set the path and python path, I've tried to run macs2 and I have the following error message
Traceback (most recent call last):
File "/home/projas/MACS2-2.1.1.20160309/bin/macs2", line 31, in <module>
from MACS2.Constants import *
ImportError: No module named 'MACS2'
does anyone know whats going on?
Thanks!
Is it possible to use the Anaconda package manager to install?
Simply download Anaconda, and then do
conda install -c bioconda macs2
Thanks, it totally works now!
I'm not familiar with the software, but it looks like a standard python error where it can't find your modules. Which installation approach did you use?
I've used that:
And after that I set my
PYTHONPATH
andPATH
as follow:Hmm, what's the output if you run
pip show MACS2
? And also, what is the output ofpython -c "import sys; print sys.path"
? We want to see if the path to the MACS2 directory is in your python path. It seems like your python is currently not looking for the module in the right place.for
pip show MACS2
and for
python -c import sys; print sys.path
is the error here?
Thank you
No sorry, did you remember the quotation marks on the last one?
python -c "import sys; print sys.path"
Sorry,
Ok, what's the output of this command:
python -c "from MACS2.Constants import *; print MACS_VERSION"
?It says:
any clues?
Yes, the python you're using to run MACS can't see the MACS directory. Try this:
export PYTHONPATH=/home/projas/MACS2-2.1.1.20160309/:$PYTHONPATH
. To check if it works, then trypython -c "from MACS2.Constants import *; print MACS_VERSION"
again. What is the output now?Hello. I encountered the same issue, and still could not get the correct answer after following steps given above. Please help. It is still saying No module named MACS2.Constants
Lila M : Please use
ADD REPLY/ADD COMMENT
when responding to existing posts to keep threads logically organized.