-
-
Notifications
You must be signed in to change notification settings - Fork 192
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enhancement : faster getTerminalNodeIDs #90
Comments
You are right, there is no option for the proximity matrix yet and |
Yes this would be great to have such a functionality ! In the meantime, for those that would like to get the terminal node IDs in a faster way, you could use the following RCpp based getTerminalNodeIDs function (which should work on numeric data) : library(Rcpp) getTerminalNodeIDs2<-function(data,rf) #example system.time(getTerminalNodeIDs(rf,iris[,-5])) 1.551 0.016 1.613system.time(getTerminalNodeIDs2(iris[,-5],rf)) 0.033 0.001 0.034 |
New option |
Thanks a lot ! On 21 September 2016 at 22:33, Marvin N. Wright notifications@github.com
|
Hi.
Thanks a lot for this brilliant package.
I would like to derive proximity matrices from forests built with ranger. As far as I know there is currently no direct builtin functionality to do so.
Yet the getTerminalNodeIds function might be used. Unfortunately this function (due to its crude R implementation) is quite slow compared with forest learning or predicting processes. I was wondering if you could speed it up or if the learning or predicting functions may also return the getTerminalNodeIds matrix or even better a proximity matrix ?
Thanks
The text was updated successfully, but these errors were encountered: