------=_NextPart_000_0006_01BD6583.73A3D5C0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hello,
I understand that the only way to expand an existing TTree database is =
by adding additional. However, how would one add data to a TTree which =
is relevant to a specific data item of a TObjArray (on an existing =
branch) and maintain a data hiarchial organization?=20
An example: When dealing with particle tracking drift chambers, one =
begins with a set of drift times for each sense wire in a given particle =
track event. These drift times are stored in a drift structure which is =
listed in a TObjArray. =20
Data stored in first branch (called raw) during first pass of data:=20
class TRawData
{=20
Int_t run number,
Int_t fill number,
...
TClonesArray *wires; // wires("TMpxEvent")
}
with=20
class TMpxEvent
{
Int _t index;
Int_t time;
T3DPoint p1;
T3DPoint p2;
...
}
Once this database of particle track events is create, drift spectrums =
are created using the entire data set which map sense wire drift times =
to distances. Now, how would I incorporate this sense wire distance =
information into the TTree such that I can reference it relative to each =
of the sense wire drift structures?
Following first pass, I can do
tree->Draw("wires.time"); // works great.
Following the second pass over data, I would like to do the following:
tree->Draw("wires.distance","time =3D xxx && index =3D xxx");
I understand this can be accomplished by moving all the sense wire data =
(TMpxEvent) directly onto the branch and performing a tree->Fill() for =
each wire, but that would require run_number, fill_number... etc in =
TRawData be written up to 50 times more often than necessary in the =
TFile.
William J Deninger
------=_NextPart_000_0006_01BD6583.73A3D5C0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD W3 HTML//EN">