October 2018
Beginner to intermediate
676 pages
18h 30m
English
The following are the steps to plot the required figure:
def c2f(temp): return (9. / 5.) * temp + 32def c2k(temp): return temp + 273.15def c2r(temp): return (9. / 5.) * temp + 427.9
def refresh_scales(ax_c): y1, y2 = ax_c.get_ylim() ax_f.set_ylim(c2f(y1), c2f(y2)) ax_f.figure.canvas.draw() ax_k.set_ylim(c2k(y1), c2k(y2)) ax_k.figure.canvas.draw() ax_r.set_ylim(c2r(y1), c2r(y2)) ax_r.figure.canvas.draw()
fig, ax_c = plt.subplots() ...
Read now
Unlock full access