moved Analysis class
group analysis methods into inner classes