import matplotlib.pyplot as plt
import numpy as np
from marvin.tools import Maps

maps = Maps('7977-12705')

halpha = maps.emline_gflux_ha_6564
nii_ha = np.log10(maps.emline_gflux_nii_6585 / halpha)
stvel = maps.stellar_vel
stsig = maps.stellar_sigma
stsig_corr = stsig.inst_sigma_correction()

with plt.style.context('seaborn-v0_8-darkgrid'):
    fig, axes = plt.subplots(nrows=2, ncols=2, figsize=(12, 11))
    halpha.plot(fig=fig, ax=axes[0, 0])
    nii_ha.plot(fig=fig, ax=axes[0, 1], title="log([NII]6585 / H-alpha)", snr_min=None)
    stvel.plot(fig=fig, ax=axes[1, 0])
    stsig_corr.plot(fig=fig, ax=axes[1, 1])