In my analysis I am interested to do correlations between different particles (let us call 1 and 2). Such correlations are corrected by mixing events, which means we fill the histograms using particle 1 and particle 2 (let say pT difference) from the same events and divide by the same distribution using particle 1 from event (or entry) 1 (let say nominal) and particle 2 from another entry (event) and/or vice-versa. Usually we do mixing by using 20 (or more) mixed events for each “nominal” event. Do you know if is still possible to use this type of mixing event in RDataFrame? Would be good to use multithreading, but if not possible, the single thread also must help.
I am afraid there is no built-in support in RDF for something like this What you can do is keep a sliding window with the values you are interested in for the last 20 events (like it’s done in the post you link to), but for random mixing it’s probably much simpler to do it with direct usage of TTreeReader or similar.