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
I think this lines (#52-54) in the gdm.transform function introduce an error in the result:
if (geo) {
predInd <- c(1, 2, predInd[-1] + 1)
}
The error appear when geo = TRUE but geographic distance has all values in the i-spline equal to zero. Then, predInd doesn't include the geographic term and removing the first element remove one of the environmental variables from the output. I guess a potential solution is to check whether geographic distance knots has all zero value and then not to remove the first element from predInd.
I think this lines (#52-54) in the
gdm.transformfunction introduce an error in the result:The error appear when
geo = TRUEbut geographic distance has all values in the i-spline equal to zero. Then,predInddoesn't include the geographic term and removing the first element remove one of the environmental variables from the output. I guess a potential solution is to check whether geographic distance knots has all zero value and then not to remove the first element frompredInd.