tuskitoo.ploting.ploting module
- plot_2d(data, vmax=None, vmin=None, interpolation=None, title='image', mask_x=None, mask_y=None, mask_color='gray', mask_alpha=0.9, origin=None, save='')[source]
Plots one or more 2D arrays as images.
- Parameters:
data (np.ndarray or list of np.ndarray) – A single 2D array or a list of 2D arrays to be plotted.
vmax (float, optional) – The upper bound of the colormap. If None, computed from np.nanquantile of each array (0.95).
vmin (float, optional) – The lower bound of the colormap. If None, computed from np.nanquantile of each array (0.05).
interpolation (str, optional) – The interpolation method to use (e.g., ‘nearest’, ‘bilinear’, etc.).
title (str, optional) – Base title to apply to each subplot.
mask_x (tuple, optional) – A tuple (x_start, x_end) specifying a vertical mask region on the plot.
mask_y (tuple, optional) – A tuple (y_start, y_end) specifying a horizontal mask region on the plot.
mask_color (str, optional) – Color to use for the masking region.
mask_alpha (float, optional) – Alpha (transparency) to use for the masking region.
origin (str, optional) – Place the [0,0] index of the array in the upper-left or lower-left corner of the axes (e.g., origin=’upper’ or origin=’lower’).
- plot_cliped_spectra(spectras, lower_percentile=0, upper_percentile=100, ylim=None, add_spectra=None, xlim=None)[source]
_summary_
- Parameters:
spectras (_type_) – _description_
lower_percentile (int, optional) – _description_. Defaults to 0.
upper_percentile (int, optional) – _description_. Defaults to 100.
ylim (_type_, optional) – _description_. Defaults to None.
- median_image(image, base=[], ylim=None, set_median=False, xlim=None, do_vertical=True, save='')[source]
- plot_spectra(flux_dict, add_error=False, save='', force_pix=False, z_s=None, add_lines=False, rest_frame=False, not_add=[], units_flux=None, units_wavelenght=None, xlim=None, add_SII=False, add_NII=False, factor=None, add_OI=False, add_HeII=False, add_Fe_lines=False, z_l=None, add_galaxy_lines=False, ima_color_dic=None, **kwargs)[source]