Example #1
0
def test_xsection_plot_map():
    radar_ds = arm.read_netcdf(
        sample_files.EXAMPLE_VISST)
    xsection = XSectionDisplay(radar_ds, figsize=(15, 8))
    xsection.plot_xsection_map(None, 'ir_temperature', vmin=220, vmax=300, cmap='Greys',
                               x='longitude', y='latitude', isel_kwargs={'time': 0})
    radar_ds.close()
    return xsection.fig
Example #2
0
def test_xsection_plot_map():
    radar_ds = arm.read_netcdf(sample_files.EXAMPLE_VISST,
                               combine='nested',
                               concat_dim='time')

    try:
        xsection = XSectionDisplay(radar_ds, figsize=(15, 8))
        xsection.plot_xsection_map(None,
                                   'ir_temperature',
                                   vmin=220,
                                   vmax=300,
                                   cmap='Greys',
                                   x='longitude',
                                   y='latitude',
                                   isel_kwargs={'time': 0})
        radar_ds.close()
        try:
            return xsection.fig
        finally:
            matplotlib.pyplot.close(xsection.fig)
    except Exception:
        pass