teaMerged: Results of an ALS analysis on individual windows

Description Usage Examples

Description

Object of class ALS: the result of the analysis of the tea data, using three time windows with an overlap parameter of 10. The three ALS models have been merged into one ALS object, which can be inspected and used for further analysis.

Usage

1

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
## generation of the data
data(tea)
new.lambdas <- seq(260, 500, by = 2)
tea <- lapply(tea.raw,
              preprocess,
              dim2 = new.lambdas)
tea.split <- splitTimeWindow(tea, c(12, 14), overlap = 10)
tea.alslist <- lapply(tea.split,
                      function(Xl) {
                        Xl.opa <- opa(Xl, 4)
                        doALS(Xl, Xl.opa)
                      })
teaMerged <- mergeTimeWindows(tea.alslist)
## This is the object saved in teaMerged.RData

ncomp <- ncol(teaMerged$S)
myPalette <- colorRampPalette(c("black", "red", "blue", "green"))
mycols <- myPalette(ncomp)

plot(teaMerged, what = "spectra", col = mycols)
legend("top", col = mycols, lty = 1, bty = "n", ncol = 2,
       legend = paste("C", 1:ncol(teaMerged$S)))

Example output

Loading required package: ALS
Loading required package: nnls
Loading required package: Iso
Iso 0.0-17
Loading required package: ptw
There were 50 or more warnings (use warnings() to see the first 50)

alsace documentation built on Nov. 8, 2020, 5:54 p.m.