fix plot button and loading