1 context("Check that dateIndexToInteger behaves as expected")
3 test_that("integer index matches date in data",
8 #TODO: with and without shift at origin (so series values at least forst ones are required)
16 level = mean(s[[index]])
17 serie = s[[index]] - level + rnorm(L,sd=0.05)
18 # 10 series with NAs for index 2
19 if (index == 2 && i >= 60 && i<= 90)
20 serie[sample(seq_len(L),1)] = NA
21 series[[i]] = list("level"=level,"serie"=serie) #no need for more :: si : time !!!
23 data = new("Data", data=series)
25 dateIndexToInteger = function(index, data)