PhD week 7: Plotting and NIR spectroscopy

[This article was first published on The Praise of Insects, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

NIR spectra-structure chart
Near-infrared (NIR) spectroscopy is a technique that measures the amount of heat absorbed or emitted by certain materials. It is used in a variety of applications, but in the agricultural world, it is often used to determine the quality and composition of mixed materials such as stock forage. It uses electromagnetic radiation in the 800 to 2500 nm range, which is just beyond the limits of our vision.

The patterns of heat absorption is determined by the functional groups present in the chemicals that make up the sample, and a degree of structural information can be obtained from the NIR spectrum of a sample. A better region to determine the structure of chemicals is in the mid-infrared region of 2500 nm to 25 000 nm. Organic chemists routinely use this region to identify the functional groups present in unknown chemicals, and there are a number of readily available charts (including Wikipedia’s effort, a 24 page practical guide and a cartoon version) that help users interpret this part of the infrared spectrum. As the NIR region is (quite rightly) not used for this degree of precision, very few charts exist. There are a couple of big, expensive books which will tell you everything you need to know (like the recently published Practical Guide and Spectral Atlas for Interpretive Near-Infrared Spectroscopy by Workman and Weyer), but in terms of getting a general idea of what functional groups absorb what parts of the spectrum, it’s a bit of a struggle to find anything.

This week I’ve been helping out a colleague do a bunch of plotting in R. It’s been good fun, and I’ve learned a number of tricks to modify the appearance of R plots. I was able to use this aspect of my week to rectify the problem identified above. I was able to track down a copy of Goddu and Delker’s 1960 near-infrared spectra-structure correlation chart, and use the information contained therein to create a dataset which I then plotted in R, to give the image shown above (a larger, better quality image is available here).

The chart shows the regions where peaks may be expected. The colours correspond to the molar absorptivity of the group at that wavelength. Darker colours correspond to a greater molar absorptivity.

The data and R commands used to create the image is available on GitHub. Caution is of course required when using this chart. The data is over 50 years old, and much research has been done since then. However, for those of us without a copy of Workman and Weyer 2012, it’s a guide to what might be going on in the region.

Goddu RF, Delker DZ. 1960. Spectra-structure correlations for the near-infrared region. Analytical Chemistry 32(1):140-141

Workman J, Weyer L. 2012. Practical Guide and Spectral Atlas for Interpretive Near-Infrared Spectroscopy. Second Edition . CRC Press: Boca Raton.

The International Code of Zoological Nomenclature

Psalms 39–43

Sixthings—Arched Text; An Inkscape Tutorial

Attractiveness of people to mosquitoes

Edgardo Donato—Colecciòn 78 rpm

Circle of Dust—Brainchild

Kiwi scientists taking drastic action to fund research—primarily focused on health research, but symptomatic of NZ science funding in general.

To leave a comment for the author, please follow the link and comment on their blog: The Praise of Insects. offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)