0

I am trying to plot one dependent variable vs two independent variables using matplotlibs heatmap feature, however, I cannot get the image to display correctly. Code and image below.

plt.xticks(np.arange(0, .015, .0015))
plt.yticks(np.arange(-.0005, .0005, .00005))
plt.scatter(Dataset.Gate, Dataset.Bias, c = Dataset.Current)

heatmap

JohanC
  • 71,591
  • 8
  • 33
  • 66
  • 2
    I think you have just set the tick positions, but not the range of the axes. That is set by `xlim` and `ylim` as described [in this comment to a related question](https://stackoverflow.com/questions/3777861/setting-y-axis-limit-in-matplotlib#comment4000268_3777861). – rubenvb Dec 01 '19 at 09:39
  • You want to plot a heatmap, but you are using `plt.scatter`. Try `plt.histogram2d` instead. – Solvalou Dec 01 '19 at 16:02

0 Answers0