I am plotting an array in matplotlib using imshow. Here is my array:
df = pd.DataFrame({'x':[1,2,2,3,3,3],'y':[1,1,2,1,2,3],'z':[3,2,4,5,1,6]})
X = df.to_numpy()
I am plotting with this:
plt.imshow(X)
How can I edit the plot so that the height of the rows are narrower? Basically, I want to reduce the vertical dimension of each square so that the height of a square is 10% the width of each square.
I have been trying to use:
plt.figure(figsize=(w,h)
But manipulating both w and h values just makes the plot bigger or smaller, keeping the same scale.
As an example of how to height of each square should be less than the width, see this below: