updated graphanalysis.py