def test_surface_plot(): """ Make a plot of the surface height of the continent. """ # create the figure fig, ax = plt.subplots() # load the dataset surface = bedmap2.load_data("surface") # show the plot im = ax.imshow(surface, cmap="inferno", extent=[-3333.5, 3333.5, -3333.5, 3333.5]) # create the colorbar axis divider = make_axes_locatable(ax) cax = divider.append_axes("right", size="5%", pad=0.1) # and some labels ax.set(xlabel="X [km]", ylabel="Y [km]", title="Surface Height") # and add the colorbar cbar = plt.colorbar(im, cax=cax) cbar.set_label("[m]") # and show the plot fig.savefig(f"{FIGDIR}/surface.png")
def test_gl04c_plot(): """ Make a plot of the gl04c to WGS84. """ # create the figure fig, ax = plt.subplots() # load the dataset factor = bedmap2.load_data("gl04c_geiod_to_WGS84") # show the plot im = ax.imshow(factor, cmap="inferno", extent=[-3333.5, 3333.5, -3333.5, 3333.5]) # create the colorbar axis divider = make_axes_locatable(ax) cax = divider.append_axes("right", size="5%", pad=0.1) # and some labels ax.set(xlabel="X [km]", ylabel="Y [km]", title="GL04C Geoid to WGS84") # and add the colorbar cbar = plt.colorbar(im, cax=cax) cbar.set_label("[m]") # and show the plot fig.savefig(f"{FIGDIR}/gl04c.png")
def test_icemask_plot(): """ Make a plot of the ice mask of the continent. """ # create the figure fig, ax = plt.subplots() # load the dataset icemask = bedmap2.load_data("icemask_grounded_and_shelves") # show the plot im = ax.imshow(icemask, cmap="inferno", extent=[-3333.5, 3333.5, -3333.5, 3333.5]) # create the colorbar axis divider = make_axes_locatable(ax) cax = divider.append_axes("right", size="5%", pad=0.1) # and some labels ax.set(xlabel="X [km]", ylabel="Y [km]", title="Ice Mask") # and add the colorbar cbar = plt.colorbar(im, cax=cax) cbar.set_label("[m]") # and show the plot fig.savefig(f"{FIGDIR}/icemask.png")