grid plot bugfix