You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Have written the below function to work with extract - only pulls MODISA daily files. This will do for now. @mdsumner would be good for you to check the function. Based off readCHL_month but had to add a couple of lines to make it work with extract().
readCHL_daily <- function(date,time.resolution = "daily", xylim = NULL, ..., inputfiles = NULL, latest = TRUE,lon180 = FALSE,
nobsonly = FALSE,
returnfiles = FALSE) {
if (is.null(inputfiles)) {
## memoize this call
files <- ocfiles("daily", product = "MODISA", varnam = "CHL", type = "L3m")
} else {
files <- inputfiles
}
if (returnfiles)
return(files)
if (missing(date)) {
if (latest) date <- max(files$date) else date <- min(files$date)
}
date <- raadtools:::timedateFrom(date)
files <- .processFiles(date, files, "daily")
rl <- lapply(files$fullname, raster::raster, varname = "chlor_a")
if (!is.null(xylim)) rl <- lapply(rl, raster::crop, raster::extent(xylim))
raster::setZ(raster::brick(rl), date)
}
Error when using
read_oc_sochla
readchla
readcha_mean
Error in spTransform(y1, projection(dummy)) :
second argument needs to be of class CRS
error origin is .big.extract
Will try to find a fix today.
The text was updated successfully, but these errors were encountered: