legend correction and uncomment figure-saving lines