Accessing ntuple data in a tree

Hi.

I store some data in a Tree, an one of the sub-branches is a Ntuple.
I now would like to access the Ntuple data from the tree, for exemple :

With that, I receive the error message : [quote]myNTule_data is not a datamember of TNtuple[/quote]

It looks like the NTuple has been store as an object and not as a sub branch.

What should I do to access my data ?

Thanks

[quote]It looks like the NTuple has been store as an object and not as a sub branch.[/quote]I am not sure what you mean …

Anyway, try to do:tree->Print();this will show you a list of the name that you can use in TTree::Draw.

Cheers,
Philippe.

[quote=“pcanal”][quote]It looks like the NTuple has been store as an object and not as a sub branch.[/quote]I am not sure what you mean …
[/quote]

I can Draw tree.NTuple.fMarkerStyle for exemple, but not the keys from the ntuple

My ntuple data keys are definitely not there.

I would have expect that branching a ntuple on a tree would create sub-branches, easily accessibles…
Is it actually possible (and how), or do I need to arrange the data in a different way ?

Thanks

Hi,

Did you put a TNtuple into a TTree? This is extremely unlikely to be what you needed/wanted to do (NTuple is a a TTree!) ?

And if you did indeed put a TNtuple inside a TTree, it will be extremely hard to extract the data of the inner TNtuple via a Draw call on the outer TTree.

Cheers,
Philippe.