Having a data set called "data", and using the openair package, I created a timePlot using the following code:
a=timePlot(data, pollutant="pm2.5", type="site", avg.time="24 hour", plot.type="s", ref.y=list(h=37, lty=2, col="black", lwd=1.6), smooth=TRUE, ci=FALSE, ylab="", main="Concentración diaria promedio PM2.5 por estación de monitoreo", ylim=c(0,50))
Yielding the following result:
Notice the reference line I added at y=37 using the ref.y
function, which represents the daily average concentration limit for pm2.5. However, I need to be 50 µg/m3 from March 1st to June 30th and 37 µg/m3 from July 1st onwards. That is according to my country's Air Quality Guidelines.
Sort of looking like this:
I'd deeply appreciate any help. Best regards.