download_co2_ml: Mauna Loa Atmospheric CO2 Concentration (Latest Data)

Description Usage See Also Examples

Description

This function downloads the monthly average atmospheric CO2 concentration (in parts per million), as measured at the Mauna Loa observatory, from a website by the NOAA Earth System Research Laboratory. The downloaded data is subsequently imported into R and returned as a uts object.

Usage

1

See Also

Users without internet connection can access the already imported data via co2_ml. However, to get the most recent data it is recommended to use this function.

co2_20ma for a 20 million year reconstruction.

The co2 dataset in base R is very similar, but ends in 1997 and has several missing values filled in using linear interpolation.

Examples

1
2
3
4
5
6
7
8
9
co2_ml <- download_co2_ml()
plot(co2_ml)
table(round(diff(co2_ml$times) * 12 / 365))  # most observations are one month apart

# Save data
## Not run: 
  save(co2_ml, file=file.path("data", "co2_ml.rda"), compress="xz")

## End(Not run)

andreas50/utsData documentation built on May 13, 2019, 12:52 p.m.