Open brookslogan opened 3 years ago
It appears that intercept=TRUE is incompatible with noncross=TRUE (at least with multiple tau groups):
intercept=TRUE
noncross=TRUE
qarr = array(42, c(6,3,5)) # or try aperm(apply(array(rexp(6*3*5), c(6,3,5)), 1:2, sort), c(2:3, 1L)) y = 1:6 # or try qarr[,1,1] + rnorm(6) tau = c(0.1, 0.3, 0.5, 0.7, 0.9) tau_groups = c(1,2,2,2,3) quantile_ensemble(qarr, y, tau, tau_groups=tau_groups, intercept = TRUE, nonneg = FALSE, unit_sum = FALSE, noncross = TRUE)
produces
Error in a0[, , k] <- cbind(rep(1, n0), q0[, , k]) : number of items to replace is not a multiple of replacement length
Replacing
n0 = dim(q0)[1]; a0 = array(NA, dim=c(n0,p,r))
with
n0 = dim(q0)[1]; a0 = array(NA, dim=c(n0,1+p,r))
generates a different error:
Error in replCmat4(x, i1 = if (iMi) 0:(di[1] - 1L) else .ind.prep2(i, : number of items to replace is not a multiple of replacement length
from from line 351 in quantile_ensemble.R:
B[(k-1)*n0 + 1:n0, (k-1)*p + 1:p] = -q0[,,k]
which looks like it will require a bit more thought to debug.
It appears that
intercept=TRUE
is incompatible withnoncross=TRUE
(at least with multiple tau groups):produces
Replacing
with
generates a different error:
from from line 351 in quantile_ensemble.R:
which looks like it will require a bit more thought to debug.