implement ANALYZE and RUN_ALL; ready for testing