I have this dateframe:
I would want to create a contour map with this data and I tried doing:
x= np.arange(0, 430, 431)
y= np.arange(0, 224, 225)
value = df["Value"].values
X, Y = np.meshgrid(x, y)
plt.contour(X, Y, value, 50)
I'm having this when executing the program:
I don't know what to do now... I think there's something wrong with the Z, I think it's 1D and I should be 2D but I have no idea. Thanks for you help.
EDITED
I have used the following code:
x = np.arange(431)
y = np.arange(225)
X, Y = np.meshgrid(y, x)
values = df["Value"].values
values2d = np.reshape(values,(431,225))
plt.contour(X, Y, values2d, 100, cmap='RdGy'))
And I'm getting:
When using Y, X = np.meshgrid(y, x)
intead I'm getting:
It must be something wrong when representing the values. Thanks.