Not that i'm an expert in R programming
(ditto in solving classification problems :-)
But i'm confident enough that integrating Tableau
with external services (R or Python) could be complicated.
The complications are mainly because of the "late integration".
Tableau treats every SCRIPT_...() function as a Table Calc one.
This could be a problem -- if there is a need to re-use the result.
One should be writing another Table Calc referring to this one.
A "simple" aggregation (binning) would become a nightmare.
Frankly, in your particular case it is possible to "count Subjects" in bins --
to calculate bin sizes for the [randforest_bool] values (both True and False).
This could be done via creative usage of RANK() functions (Table Calculations).
Please find the attached as an example.
The Sheet 7 view is mirroring the Sheet 7 bool one
(the results are the same, but please check the field order
in the Addressing window for every Table Calc on both,
different order gives different results of counts in bins).
Hope it could help understanding.
example_Routput_v10.5_YF.twbx 81.9 KB
Thank you for your suggestion! I am new to Tableau and I still need to better understand Table Calculations, but it is usefull to see how you did it. I believe this approach will help me to perform some other calculations with the R-script output that I though would not be possible!
Elena, you're welcome.