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 have tried to resolve it by uninstalling and reinstalling pysam

Make sure you install pysam for the right python version. In your case, I suggest:

    python2.7 -m pip install pysam