Tue, 10 Dec 2019 13:24:02 +0200
More flexible scan plots.
atmospheric_lidar/raymetrics.py | file | annotate | diff | comparison | revisions |
--- a/atmospheric_lidar/raymetrics.py Fri Nov 01 18:13:03 2019 +0200 +++ b/atmospheric_lidar/raymetrics.py Tue Dec 10 13:24:02 2019 +0200 @@ -315,7 +315,7 @@ def plot_scan(self, figsize=(8, 4), signal_type='rc', z_min=0., z_max=12000., show_plot=True, cmap=plt.cm.jet, vmin=0, vmax=1.3 * 10 ** 7, mask_noise=True, noise_threshold=1., cb_format='%.0e', - box=False): + box=False, grid=(1, 4), ax1_position=(0, 0), ax1_span=2, ax2_position=(0, 2), ax2_span=2): """ Plot data as RHI and PPI scans. @@ -347,8 +347,9 @@ Threshold to use in the noise masking routine. """ fig = plt.figure(figsize=figsize) - ax1 = fig.add_subplot(121) - ax2 = fig.add_subplot(122) + + ax1 = plt.subplot2grid(grid, ax1_position, colspan=ax1_span) + ax2 = plt.subplot2grid(grid, ax2_position, colspan=ax2_span) self.draw_ppi(ax1, cmap=cmap, signal_type=signal_type, z_min=z_min, z_max=z_max, vmin=vmin, vmax=vmax, mask_noise=mask_noise, noise_threshold=noise_threshold, add_colorbar=False, cb_format=cb_format,