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
The partial() function fails on ranger objects unless the data= argument is explicitly named in the call. get_training_data.default() could use match.call() to figure out the names when they are not specified. Also, it calls eval() without an environment argument. The calling environment should be passed down the stack so that the evaluation happens in the right frame, although even that is not fool-proof. Why is there a check for S4 objects? There could be a getCall() method for an S4 class just as easily as for an S3 class.
The text was updated successfully, but these errors were encountered:
Good catch! This is not specific to ranger either. Honestly this function was only meant to be helpful in very general cases as it's always better to specify the training data via the train argument in the call to pdp::partial(). I'll try to push a fix relatively soon.
The
partial()
function fails on ranger objects unless thedata=
argument is explicitly named in the call.get_training_data.default()
could usematch.call()
to figure out the names when they are not specified. Also, it callseval()
without an environment argument. The calling environment should be passed down the stack so that the evaluation happens in the right frame, although even that is not fool-proof. Why is there a check for S4 objects? There could be agetCall()
method for an S4 class just as easily as for an S3 class.The text was updated successfully, but these errors were encountered: