QuantileMappping doesn't allow to have member dimension to NULL. For example this:
exp <- 1 : c(1 * 1 * 6 * 3 * 8 * 8)
dim(exp) <- c(dataset = 1, sdate = 6, ftime = 3, lat = 8, lon = 8)
obs <- 101 : c(100 + 1 * 1 * 6 * 3 * 8 * 8)
dim(obs) <- c(dataset = 1, sdate = 6, ftime = 3, lat = 8, lon = 8)
QuantileMapping(exp, obs, memb_dim = NULL)
# Error in obs[, -sd] : incorrect number of dimensions
With the change:
res <- QuantileMapping(exp, obs, memb_dim = NULL)
dim(res)
# sdate dataset ftime lat lon
# 6 1 3 8 8