save histogram