imported analysis code from CMGTools. JSONAnalyzer working