#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Mon Dec 11 17:36:45 2023

@author: mzannese
"""

import matplotlib.pyplot as plt
import numpy as np

fig, ax = plt.subplots(2, figsize=(30, 10), sharex=True)
ax[0].set_ylim(-60, 300)
ax[1].set_ylim(-60,300)

ax[0].set_xlim(9.09, 10.45)

data = np.loadtxt('/PDRs4All_d203-506_fig2_Zannese24.txt')

wave = data[:, 0]
intensity=data[:,3]
modelOH_sym=data[:,4]
modelOH_equal=data[:,5]

ax[0].step(wave, intensity, c='black',where='mid')
ax[0].fill_between(wave,modelOH_sym,step='mid',lw=1.5,color='r',zorder=0,alpha=0.8)
ax[1].step(wave,modelOH_equal,c='lightgray',where='mid')
ax[1].step(wave,modelOH_sym,c='r',where='mid')


fig.supylabel('Intensity (MJy/sr)')
fig.supxlabel('Wavelength ($\mu$m)')