Plotting Functions

Different plots that can be made of images, or combinations of images. These are the functions which use an existing axis, for more complete functions which return a whole figure see reports.py

imtools.plots.plot_I(ax, image, units='Jy', cmap='afmhot', add_title=True, clean=False, tag='', **kwargs)

Plot Stokes I. Separate implementation for afmhot colors and black background

imtools.plots.plot_Q(ax, image, **kwargs)

Plot Stokes Q

imtools.plots.plot_U(ax, image, **kwargs)

Plot Stokes U

imtools.plots.plot_V(ax, image, **kwargs)

Plot Stokes V

imtools.plots.plot_all_stokes(axes, image, relative=False, vmax=None, units='Jy', n_stokes=4, layout='none', polar=False, all_magnitudes=False, all_angles=False, **kwargs)

Plot all raw Stokes parameters on a set of 4 axes. If vmax is given as a list, use the respective elements as vmax for I,Q,U,V

imtools.plots.plot_cpfrac(ax, image, cmap='jet', **kwargs)

Plot the percentage of emission which is circularly polarized. Signed. (as in ipole’s bundled plot_pol.py)

imtools.plots.plot_evpa_rainbow(ax, image, evpa_conv='EofN', cmap='hsv', clean=False, **kwargs)

EVPA rainbow plot – color pixels by angle without regard to polarized emission fraction (as in ipole’s bundled plot_pol.py)

imtools.plots.plot_evpa_ticks(ax, image, n_evpa=20, scale='emission', emission_cutoff=0.0, fov_units='muas', custom_wid=1.0, prominent=False, compress_scale=False, **kwargs)

Superimpose EVPA as a quiver plot, either scaled by the polarization fraction or not.

imtools.plots.plot_lp(ax, image, cmap='afmhot', clean=False, **kwargs)

Plot the percentage of emission which is linearly polarized.

imtools.plots.plot_lpfrac(ax, image, cmap='jet', clean=False, **kwargs)

Plot the percentage of emission which is linearly polarized.

imtools.plots.plot_one_stokes(ax, image, num, units='Jy', cmap='bwr', vmax=None, add_title=True, clean=False, tag=None, **kwargs)

Plot the Stokes parameter indicated by num, where I==0, Q==1, etc.

imtools.plots.plot_unpolarized(ax, image, units='Jy', cmap='afmhot', add_title=True, clean=False, tag='', **kwargs)

Plot the image result of unpolarized transport. Separate implementation for afmhot colors and black background.

imtools.plots.plot_var(ax, var, image, fov_units='muas', xlabel=True, ylabel=True, add_cbar=True, clabel=None, zoom=1, clean=False, symmetric=False, log=False, **kwargs)

General function for plotting a set of pixels, given some options about how to do it

imtools.plots.subplots_adjust_square(fig, nx, ny, bottom=0.05, top=0.95, left=0.05, right=0.95, global_cbar=False, col_cbars=False)

Adjust the height of a grid with aspect=’equal’ so that there is no space between rows or columns. If global_cbar=True, adjust for the extra width and return a suitable set of axes