Hi, I have a TTree with a branch that contains an std::map<int,Hot> where a Hot is a POD struct with only numerical values:
struct Hot
{
Double_t doca;
Double_t delta_doca;
Bool_t excluded;
Double_t chi2_contribution;
};
Is it possible to use TTree::Draw to access the members of the Hots in the std::map? I probably need to load a dictionary or something, but when I do “.L JFTrackFit.C+” (which contains the Hot definition) it doesn’t seem to change the error messages I get. Perhaps I also do not have the right syntax for accessing the std::map elements. I tried:
root [3] Proto2Analyzed->Draw("track_hots[12].doca")
root [4] Proto2Analyzed->Draw("(track_hots[12]).doca")
root [5] Proto2Analyzed->Draw("track_hots.at(12).doca")
root [6] Proto2Analyzed->Draw("(track_hots.at(12)).doca")
root [7] Proto2Analyzed->Draw("*(track_hots.find(12)).doca")
root [8] Proto2Analyzed->Draw("track_hots.find(12)->doca")
root [9] Proto2Analyzed->Draw("(*track_hots.find(12))doca")
but I just get different errors about either syntax, unknown method, or “We thought we had a function but we don’t”.
Thanks for any help getting this to work.
Jean-François