[R] The way giving the suitable data structure to the obtained data for the use of "prospectr"
Jim Lemon
drj|m|emon @end|ng |rom gm@||@com
Thu Sep 19 23:50:20 CEST 2019
Hi rhotuser,
Your question is really not about R, but about understanding IR
spectroscopy methods for soil composition. That's not my field, and
you will be lucky to find someone on this help list who is:
1) an expert in the field
2) willing to explain the methods used in the prospectr package
Maybe reading an introduction to the field will be a good start:
https://en.wikipedia.org/wiki/Near-infrared_spectroscopy
then a Google search for "NIR soil analysis"
Jim
On Fri, Sep 20, 2019 at 3:39 AM <rhotuser using yahoo.co.jp> wrote:
>
> Dear Sir,
> I want to use the "prospectr" for the obtained spectra like the attached file, "Nirspectra".
> However, my understanding level of the data structure of "NIRsoil" is not yet enough.
> reference: https://cran.r-project.org/web/packages/prospectr/vignettes/prospectr-intro.pdf
> data(NIRsoil)str(NIRsoil) -----> A little complicated for me.
> I have 2 questions.
> I want to make the data structure of "Nirspectra" to be applied directly for "prospectre".
> 1. Please tell me the detail way for giving suitable data structure toward "Nirspectra".
> abc<-read.csv('Nirspectra.csv')
>
> ------------------------------------------------------------------------------- My estimation of the final data sturucture of "Nirspectra" for the direct use of "prospectr"
> 'data.frame': 57 obs. of 3 variables: $ train: num 1 1 0 1 1 0 1 1 0 1 ... $ dep : num 87.300003 87 87.099998 89.699997 84.900002 84.699997 89.300003... $ spc : num [2:58, 1:36] ...
> 2. Which is right, num [2:58, 1:36] or num [1:58, 1:36] ?
> Best Regards,______________________________________________
> R-help using r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help
mailing list