Loading an IR (omnic SPG) experimental file

Here we load an experimental SPG file (OMNIC) and plot it.

import spectrochempy as scp

Loading and stacked plot of the original

datadir = scp.preferences.datadir
dataset = scp.read_omnic(datadir / "irdata" / "nh4y-activation.spg")
dataset.plot_stack(style="paper")
plot read IR from omnic


change the unit of y-axis, the y origin as well as the title of the axis

dataset.y.to("hour")
dataset.y -= dataset.y[0]
dataset.y.title = "acquisition time"

dataset.plot_stack()
plot read IR from omnic


This ends the example ! The following line can be uncommented if no plot shows when running the .py script with python

# scp.show()

Total running time of the script: (0 minutes 0.354 seconds)