Hello all. I have been having issues on running a python script. I have tried to resolve it by uninstalling and reinstalling pysam since the error is about pysam mostly. below is the command and error i get.
$ python2.7 overlapping_reads.py
Traceback (most recent call last):
File "overlapping_reads.py", line 4, in <module>
import pysam
ImportError: No module named pysam
Can someone help?also, belo is portion of my script if that helps. Thanks
import argparse
from collections import defaultdict
import pysam
def Parser():
the_parser = argparse.ArgumentParser()
the_parser.add_argument(
'--input', action="store", type=str, help="bam alignment file")
the_parser.add_argument(
'--minquery', type=int,
help="Minimum readsize of query reads (nt) - must be an integer")
the_parser.add_argument(
'--maxquery', type=int,
help="Maximum readsize of query reads (nt) - must be an integer")
the_parser.add_argument(
'--mintarget', type=int,
I added code markup to your post for increased readability. You can do this by selecting the text and clicking the 101010 button. When you compose or edit a post that button is in your toolbar, see image below:
This is most likely the case where you are using a
pip
command associated with a differentpython
installation.Please share the exact command used to install
pysam
. That could help decide what to do next to figure out wherepysam
might be getting installed.this is what I used. conda install -c bioconda pysam=0.9.1