Analysis tools for CMS