Closed kapitzas closed 7 years ago
workflow that combines LocalRaster() covariates and Background() with bias layer cannot be completed due to the following error:
Caught` errors: Error in `[.data.frame`(.df, , attr(.df, "covCols")): undefined columns selected
The error stems from Background() line 94 attr(df, 'covCols') <- names(ras). When a biaslayer is provided it gets passed to function object ras, and names(ras) becomes the name of the biaslayer, rather than names from the covariate stack.
attr(df, 'covCols') <- names(ras)
ras
names(ras)
Thanks Simon!
For anyone else reading this, the problem should be easy to fix and Simon is working on it.
workflow that combines LocalRaster() covariates and Background() with bias layer cannot be completed due to the following error:
The error stems from Background() line 94
attr(df, 'covCols') <- names(ras)
. When a biaslayer is provided it gets passed to function objectras
, andnames(ras)
becomes the name of the biaslayer, rather than names from the covariate stack.