Skip to content
Prev 21835 / 29559 Next

spacetime EOF error "variable names are limited to 10000 bytes"

Thanks for the quick fix, Edzer!

I was unfamiliar with installing a development version of a package from
GitHub.  If anyone comes across this, it's pretty easy with the devtools
library:


library(raster)
library(spacetime)
library(devtools)

## Create a raster object that mimics my data
## I actually have 20,708 layers in the raster stack
a = array(rnorm(9*9*10000), c(9,9,10000))
b = brick(a)
b = setValues(b, a)
z = seq(as.Date('1980-01-01'), as.Date('2007-05-18'),
        by = 'day')
b = setZ(b, z)

## Turn on dev_mode in devtools to easily
## compile spacetime from GitHub
dev_mode(on=TRUE)
install_github('edzer/spacetime')

## coerce the raster stack to an STFDF object
stfdf = as(b, 'STFDF')

## attempt to compute EOFs
eof_time = EOF(stfdf, 'temporal')
eof_space = EOF(stfdf, 'spatial')


On Tue, Oct 14, 2014 at 12:27 AM, Edzer Pebesma <
edzer.pebesma at uni-muenster.de> wrote: