clean up main chart controller