data-science

pwrflx 2024-09-18T19:03:41.242919Z

Anyone experienced with random forests in Clojure? I guess there is no proper native implementation, but calling over to R/Python and somehow visualizing the result using Clay? (I've checked and Plotly JS does not have a tree component for some reason, so that is not a solution in this case)

Daniel Slutsky 2024-09-18T20:35:59.233699Z

Hi. There is some initial documentation for that at the Noj project: https://scicloj.github.io/noj/ It'd be better to discuss such topics at the Clojurians Zulip chat, where most of the relevant people are more present. https://scicloj.github.io/docs/community/chat/

👍 1
Daniel Slutsky 2024-09-18T20:37:56.166929Z

The Noj tutorials are using https://github.com/scicloj/scicloj.ml.tribuo , which wraps Tribuo, a Java library with many machine learning algorithms. I'm curious to hear your thoughts about them, and will be glad do look together about how to make them clearer and more informative.

Daniel Slutsky 2024-09-18T20:48:47.221129Z

If you wish to actually visualize the trees themselves, we will need to extract them from the Java classes of Tribuo. It should be doable. But R and Python have more diverse options in that area: https://cran.r-project.org/web/packages/ggparty/vignettes/ggparty-graphic-partying.html https://github.com/parrt/dtreeviz

👍 1
2024-09-19T19:08:54.865349Z

scicloj.ml.smile has as well a RF implementation. Here is shown how to get the "tree" for model deciosn tree. BUt its smiliar for RF, just having multiple trees https://github.com/scicloj/scicloj.ml-tutorials/blob/7cf7af0404643e589138a87f21edf83d13a56532/src/scicloj/ml/models.clj#L170 Smile decision tree model retun the tree as a ".dot", file which can be converted to svg. I used an online service for this in the tutorial,

👍 1
🙏 1