I have the following
traceback and I would like some help to understand/solve it.
Can anyone explain to me what to look here?
6: stop("cannot use this formula, probably because it is not vectorized") 5: .overlayList(x, fun = fun, filename = filename, forcefun = forcefun, ...) 4: .local(x, y, ...) 3: raster::overlay(x, fun = tslp, ...) 2: raster::overlay(x, fun = tslp, ...) 1: raster.kendall(raster_stack, tau = TRUE, intercept = TRUE, p.value = TRUE, z.value = TRUE, confidence = TRUE)
dates<-as.data.frame( as.Date(c('2010-10-1','2009-5-26','2008-5-10','2007-3-13','2006-2-2'))) rst = raster(matrix(1:15,3,4)) raster_stack = stack(rst,rst,rst,rst,rst) raster_stack <- setZ(raster_stack, dates[,1], "my_dates")