Errors in running code in vignettes:
when running code in 'article.Rnw'

> options(prompt = "R> ", continue = "+  ", width = 70, 
+     useFancyQuotes = FALSE)

> library("MASS")

> library("trajectories")

> library("trajectories")

> set.seed(10)

> library("spacetime")

> library("sp")

> t0 = as.POSIXct(as.Date("2013-09-30", tz = "CET"))

> x = c(7, 6, 5, 5, 4, 3, 3)

> y = c(7, 7, 6, 5, 5, 6, 7)

> n = length(x)

> t = t0 + cumsum(runif(n) * 60)

> crs = CRS("+proj=longlat +datum=WGS84")

> stidf = STIDF(SpatialPoints(cbind(x, y), crs), t, 
+     data.frame(co2 = rnorm(n, mean = 10)))

> A1 = Track(stidf)

> A1
An object of class Track 
7points 
bbox: 
  min max
x   3   7
y   5   7
Time period: [2013-09-30 02:00:30, 2013-09-30 02:02:31]
> plot(A1)

> x <- runif(10, 0, 1)

> y <- runif(10, 0, 1)

> date <- seq(as.POSIXct("2015-1-1 0:00"), as.POSIXct("2015-1-1 9:00"), 
+     by = "hour")

> records <- as.data.frame(rpois(10, 5))

> as.Track(x, y, date, covariate = records)
An object of class Track 
10points 
bbox: 
         min       max
x 0.23958913 0.8382877
y 0.09308813 0.9546536
Time period: [2015-01-01, 2015-01-01 09:00:00]
> x = c(7, 6, 6, 7, 7)

> y = c(6, 5, 4, 4, 3)

> n = length(x)

> t = max(t) + cumsum(runif(n) * 60)

> stidf = STIDF(SpatialPoints(cbind(x, y), crs), t, 
+     data.frame(co2 = rnorm(n, mean = 10)))

> A2 = Track(stidf)

> A = Tracks(list(A1 = A1, A2 = A2))

> A
An object of class Tracks 
2 tracks followed by a single object
> x = c(2, 2, 1, 1, 2, 3)

> y = c(5, 4, 3, 2, 2, 3)

> n = length(x)

> t = max(t) + cumsum(runif(n) * 60)

> stidf = STIDF(SpatialPoints(cbind(x, y), crs), t, 
+     data.frame(co2 = rnorm(n, mean = 10)))

> B1 = Track(stidf)

> x = c(3, 3, 4, 3, 3, 4)

> y = c(5, 4, 3, 2, 1, 1)

> n = length(x)

> t = max(t) + cumsum(runif(n) * 60)

> stidf = STIDF(SpatialPoints(cbind(x, y), crs), t, 
+     data.frame(co2 = rnorm(n, mean = 10)))

> B2 = Track(stidf)

> B = Tracks(list(B1 = B1, B2 = B2))

> Tr = TracksCollection(list(A = A, B = B))

> Tr
An object of class TracksCollection 
2 collection of tracks followed by 2  object
> dim(A1)
geometries 
         7 

> dim(B1)
geometries 
         6 

> stbox(A1)
    x y                time
min 3 5 2013-09-30 02:00:30
max 7 7 2013-09-30 02:02:31

> downsample(A1, B1)
An object of class Track 
6points 
bbox: 
  min max
x   3   7
y   5   7
Time period: [2013-09-30 02:00:30, 2013-09-30 02:02:31]
> stplot(Tr, attr = "co2", arrows = TRUE, lwd = 3, by = "IDs", 
+     cex.axis = 2)

> set.seed(10)

> x <- rTrack()

> x
An object of class Track 
100points 
bbox: 
        min       max
x -53.38677 -3.232289
y -53.08787 -1.594295
Time period: [1970-01-01, 1970-01-01 01:39:00]
> y <- rTrack(transform = T)

> y
An object of class Track 
100points 
bbox: 
  min max
x   0   1
y   0   1
Time period: [1970-01-01, 1970-01-01 01:39:00]
> m <- matrix(c(0, 10, 0, 10), nrow = 2, byrow = T)

> w <- rTrack(bbox = m, transform = T)

> w
An object of class Track 
100points 
bbox: 
  min max
x   0  10
y   0  10
Time period: [1970-01-01, 1970-01-01 01:39:00]
> z <- rTrack(bbox = m, transform = T, nrandom = T)

> z
An object of class Track 
108points 
bbox: 
  min max
x   0  10
y   0  10
Time period: [1970-01-01, 1970-01-01 01:47:00]
> par(mfrow = c(2, 2), mar = rep(2.2, 4))

> plot(x, lwd = 2, main = "x")

> plot(y, lwd = 2, main = "y")

> plot(w, lwd = 2, main = "w")

> plot(z, lwd = 2, main = "z")

> library("forecast")

  When sourcing 'article.R':
Error: there is no package called 'forecast'
Execution halted

  'article.Rnw'... failed