Collection of non-meaningful error messages / handling
davidruegamer opened this issue · 2 comments
davidruegamer commented
- For SOF models, which are specified with a data list containing a response with a wrong length (e.g. response has length 7 and covariates have length 8 or 8 rows, FDboost does not throw an error until the
df2lambda
function tries to do the cholesky decomposition with wrong weights (credits to Joanna)
fuelSubset$heatan <- fuelSubset$heatan[1:100]
sof <- FDboost(heatan ~ bsignal(NIR, nir.lambda, knots = 20, df = 4),
timeformula = NULL, data = fuelSubset)
davidruegamer commented
Not saying, that we should deal with all of those errors, but some may improve the package handling:
- Error handling when defining knots = 0 : The first line does meaningful things, the second doesn't:
str(with(fuelSubset, bsignal(NIR, nir.lambda, knots = 0)),1)
sof <- FDboost(heatan ~ bbs(h2o, df = 4)
+ bsignal(UVVIS, uvvis.lambda, knots = 20, df = 4)
+ bsignal(NIR, nir.lambda, knots = 0, df = 4),
timeformula = NULL, data = fuelSubset)
Why is that? Our problem? EDIT: It is possible to construct a design matrix with zero knots but it is not possible to invert t(X)%*%X
in this case. So I think this isn't our problem...
- Better error handling for missing
timeformula
? Set a default? - When forgetting the tilde in
timeformula
,complete.cases
throws a quite mysterious error message:
fos_intercept <- FDboost(EMG ~ 1,
timeformula = bbs(t, df = 2),
data = emotion)
- Same for id in the long format case.
FDboost
reports, that it can not find the id object, instead of reporting a wrong specified argument:
fos_intercept_long <- FDboost(EMG ~ 1,
timeformula = ~ bbs(time_long, df = 4),
id = curveid, data = emotion_long)
davidruegamer commented
- Dimension problem with non-meaningful error message also present for FOF regression