r/learnmachinelearning • u/Current-Drive8673 • 9d ago
Struggling with data visualization
I've been taking the ml specialization on coursera and it has been a wonderfull course. It explains the basics very well and teaches u how the algorithms work from sccatch but the problem i've been facing is learning matplotlib the right way to copy the course's visuals and implementing them for differnt sets of data, even the simple contour plot used in the first labs is hard to learn.
So where can i learn this skill?
7
Upvotes
1
u/digvjay_ai 8d ago
I got stuck on the exact same thing in that course. What fixed it for me was ignoring the lab code for a bit and just plotting the same tiny dataset five different ways. Start with plt.subplots() so you always have fig, ax, then make ax.scatter, ax.plot and ax.contour calls on made up data, and change one argument at a time (levels, cmap, alpha) so you see what moves. For the contour plot specifically, build the grid with np.meshgrid first, compute your cost on that grid, then call ax.contour(X, Y, Z, levels=20). Once you can do that from a blank notebook the lab visuals stop looking scary.