I'm trying to create a countourf plot with the region in the bottom left hand corner whited out. Values for the contour are provided at the corner of each rectangle in the below image and all other points on the mesh have a value of NaN.
I want to know how to stop the countourf plot from drawing the triangular section at the top right of the white square, i.e. how do I stop it from interpolating across these two values.
End game: I would like a complete white rectangle on the bottom left, not a chamfered rectangle.
You are getting that triangle because on that specific square your data looks something like:
And that is a completely valid upper right triangle to contour.
So you can interpolate your data to get more resolution and make that triangle smaller. Or you could just use
patch
to add a white square at the desired position.