khliland / pls

The pls R package
36 stars 3 forks source link

pls package example in R #32

Closed Catrin-Landseer closed 3 years ago

Catrin-Landseer commented 3 years ago

In the gasoline dataset used as an example for the pls run-through in R, I am unsure about how the NIR values are obtained. How were all 401 diffuse reflectance measurements condensed from a range of 900 to 1700 nm into a single NIR value? Were the octane numbers known before too? Thanks.

khliland commented 3 years ago

The NIR part of the gasoline data.frame contains a matrix of 401 columns (2 nm spacing from 900 to 1700 nm). You will find the description of the data set if you attach the pls package and write ?gasoline in the console.

Catrin-Landseer commented 3 years ago

Yes, thanks for the reply. I've had a look at the description of the dataset and am aware of the matrix of 401 columns, but am still confused about how a single NIR value was obtained - surely there are reflectance values for each wavelength. At what wavelength were those NIR values taken? Or is one NIR value an average reflectance across a range of wavelengths? Thanks

khliland commented 3 years ago

I am not quite sure where the single NIR value comes in. The data.frame called gasoline contains two elements:

Catrin-Landseer commented 3 years ago

Okay, that's great. Thank you!