This document evaluates computation times and speedup factors using set_default_options() and set_fast_options(). The same functions from benchmark.R are applied for both option settings. Results are summarized below.

f time.default time.fast speedup
bfast.olscusum 8.13 2.98 2.728188
bfast.olsmosum 8.94 1.93 4.632124
bfast.reccusum 8.76 2.14 4.093458
bfast.recmosum 8.04 2.79 2.881720
bfast01.test 6.49 5.71 1.136602
bfastmonitor.hist.all 3.40 1.08 3.148148
bfastmonitor.hist.bp 6.64 0.78 8.512821
bfastmonitor.hist.roc 7.45 1.81 4.116022
bfastmonitor.ME 8.05 1.31 6.145038
bfastmonitor.modis 10.13 3.32 3.051205
bfastmonitor.olscusum 7.04 1.53 4.601307
bfastmonitor.RE 9.49 1.17 8.111111

Function details

bfast.olscusum

function() {
  replicate(5,bfast(harvest,h=rdist, type="OLS-CUSUM", season="harmonic", max.iter = 1))
}
<environment: 0x00000000190e2c10>

bfast.olsmosum

function() {
  replicate(5,bfast(harvest,h=rdist, type="OLS-MOSUM", season="harmonic", max.iter = 1))
}
<environment: 0x00000000190e2c10>

bfast.reccusum

function() {
  replicate(5,bfast(harvest,h=rdist, type="Rec-CUSUM", season="harmonic", max.iter=1))
}
<environment: 0x00000000190e2c10>

bfast.recmosum

function() {
  replicate(5,bfast(harvest,h=rdist, type="Rec-MOSUM", season="harmonic", max.iter = 1))
}
<environment: 0x00000000190e2c10>

bfast01.test

function() {
  replicate(100,bfast01(NDVIa, test = c("BIC", "OLS-MOSUM", "supLM"), aggregate = any))
}
<environment: 0x00000000190e2c10>

bfastmonitor.hist.all

function() {
  replicate(300,bfastmonitor(NDVIa, start = c(2010, 13),history = "all", type="OLS-MOSUM",formula = response ~ trend + harmon,order=3,lag = NULL, slag = NULL))
}
<environment: 0x00000000190e2c10>

bfastmonitor.hist.bp

function() {
  replicate(5,bfastmonitor(NDVIa, start = c(2010, 13),history = "BP", type="OLS-MOSUM",formula = response ~ trend + harmon,order=3,lag = NULL, slag = NULL))
}
<environment: 0x00000000190e2c10>

bfastmonitor.hist.roc

function() {
  replicate(300,bfastmonitor(NDVIa, start = c(2010, 13),history = "ROC", type="OLS-MOSUM",formula = response ~ trend + harmon,order=3,lag = NULL, slag = NULL))
}
<environment: 0x00000000190e2c10>

bfastmonitor.ME

function() {
  replicate(50,bfastmonitor(NDVIa, start = c(2010, 13),history = "ROC", type="ME",formula = response ~ trend + harmon,order=3,lag = NULL, slag = NULL))
}
<environment: 0x00000000190e2c10>

bfastmonitor.modis

function() {
  ## helper function to be used with the calc() function
  xbfastmonitor <- function(x,dates) {
    ndvi <- bfastts(x, dates, type = c("16-day"))
    ndvi <- window(ndvi,end=c(2011,14))/10000
    ## delete end of the time to obtain a dataset similar to RSE paper (Verbesselt et al.,2012)
    bfm <- bfastmonitor(data = ndvi, start=c(2010,12), history = c("ROC"))
    return(cbind(bfm$breakpoint, bfm$magnitude))
  }
  x <-replicate(10,calc(modisbrick,function(x) {xbfastmonitor(x, dates)}))
}
<environment: 0x00000000190e2c10>

bfastmonitor.olscusum

function() {
  replicate(300,bfastmonitor(NDVIa, start = c(2010, 13),history = "ROC", type="OLS-CUSUM",formula = response ~ trend + harmon,order=3,lag = NULL, slag = NULL))
}
<environment: 0x00000000190e2c10>

bfastmonitor.RE

function() {
  replicate(50,bfastmonitor(NDVIa, start = c(2010, 13),history = "ROC", type="RE",formula = response ~ trend + harmon,order=3,lag = NULL, slag = NULL))
}
<environment: 0x00000000190e2c10>

This report has been generated on 2017-01-10 21:19:48.