MathROOT Example Notebook

•Note

This Notebook will show you how to use MathROOT, but you won't be able to evaluate it becuase it depends on my ROOT data files installed on my personal computer which you won't have. However, there are enough examples that you should be able to modify the Notebook to work with your own ROOT data files.

•Setup

Needs["Langston`Histogram`"] ;

This is MathHist version 0.8.0.0, released 2002.12.14

by Matthew D. Langston <langston@SLAC.Stanford.EDU>

Visit the MathROOT web site at http://mathhist.sourceforge.net/

mathroot = Install["mathroot.exe"] ;

This is MathROOT version 0.8.0.0, released 2002.12.14

by Matthew D. Langston <langston@SLAC.Stanford.EDU>

Visit the MathROOT web site at http://mathroot.sourceforge.net/

mathroot = Install[LinkConnect["hm3"]]

myImageSize = 7 ;

commonOptions = Sequence[Axes -> False, Frame -> True, ImageSize -> myImageSize 72] ;

scatterPlotPoints = 50000 ;

•Data

baseDirectory = {$HomeDirectory, "Physics", "analysis", "WABRecon"} ;

SetDirectory[ToFileName[baseDirectory]] ;

•Raw Data

rootFiles = FileNames["*.root", "", Infinity] ;

dataFile = Select[rootFiles, StringMatchQ[#, "*1997*"] &]

{data\\1997_cwn2cwn.root}

dataFile = ToFileName[baseDirectory, First[dataFile]]

C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data\\1997_cwn2cwn.root

GetFileMetaData[dataFile]

{AbsolutePath -> C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data\\1997_cwn2cwn.root, TreeRelativePaths -> {h10;3, h10;2}}

TreeRelativePaths /. GetFileMetaData[dataFile]

{h10;3, h10;2}

GetTreeMetaData[dataFile, #] & /@ (TreeRelativePaths /. GetFileMetaData[dataFile])

{{Name -> h10, Title -> Raw WAB Events in CWN format, AbsolutePath -> C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data\\1997_cwn2cwn.root\\h10;3, RelativePath -> h10;3, Rows -> 176242, Columns -> 8, ColumnNames -> {run, event, epol, etot, n_clus, E, cthtot, phitot}, ColumnTypes -> {Int_t, Int_t, Float_t, Float_t, Int_t, Float_t[n_clus][5], Float_t[n_clus], Float_t[n_clus]}}, {Name -> h10, Title -> Raw WAB Events in CWN format, AbsolutePath -> C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data\\1997_cwn2cwn.root\\h10;2, RelativePath -> h10;2, Rows -> 156633, Columns -> 8, ColumnNames -> {run, event, epol, etot, n_clus, E, cthtot, phitot}, ColumnTypes -> {Int_t, Int_t, Float_t, Float_t, Int_t, Float_t[n_clus][5], Float_t[n_clus], Float_t[n_clus]}}}

treeName = "h10" ;

GetTreeMetaData[dataFile, treeName]

{Name -> h10, Title -> Raw WAB Events in CWN format, AbsolutePath -> C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data\\1997_cwn2cwn.root\\h10;3, RelativePath -> h10;3, Rows -> 176242, Columns -> 8, ColumnNames -> {run, event, epol, etot, n_clus, E, cthtot, phitot}, ColumnTypes -> {Int_t, Int_t, Float_t, Float_t, Int_t, Float_t[n_clus][5], Float_t[n_clus], Float_t[n_clus]}}

GetColumnNames[dataFile, treeName]

{run, event, epol, etot, n_clus, E, cthtot, phitot}

GetColumnTypes[dataFile, treeName]

{Int_t, Int_t, Float_t, Float_t, Int_t, Float_t[n_clus][5], Float_t[n_clus], Float_t[n_clus]}

•Reconstructed Data

dataFile = ToFileName[Join[baseDirectory, {"data_cwn2cwn", "100 MeV Cluster Quality Cut"}], "wab_recon.root"]

C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data_cwn2cwn\\100 MeV Cluster Quality Cut\\wab_recon.root

GetFileMetaData[dataFile]

{AbsolutePath -> C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data_cwn2cwn\\100 MeV Cluster Quality Cut\\wab_recon.root, TreeRelativePaths -> {1993_wab_recon;1, 1994_wab_recon;1, 1995_wab_recon;1, 1996_wab_recon;1, 1997_wab_recon;1, 1998_wab_recon;1}}

treeName = "1997_wab_recon" ;

GetTreeMetaData[dataFile, treeName]

{Name -> 1997_wab_recon, Title -> 1997 Reconstructed WAB Events, AbsolutePath -> C:\\Documents and Settings\\Matthew D. Langston\\My Documents\\Physics\\analysis\\WABRecon\\data_cwn2cwn\\100 MeV Cluster Quality Cut\\wab_recon.root\\1997_wab_recon;1, RelativePath -> 1997_wab_recon;1, Rows -> 175564, Columns -> 30, ColumnNames -> {run, event, epol, etot, etot_imb, thrust, thrust2, thrust3, imb, rapidity, cthcms, beta, e_isr_photon_imb, e_isr_photon, s_prime, s_prime_imb, x, n_clus_tot, n_clus_mag, n_clus_em, n_clus, E, cthtot, phitot, clus_index, cuts, clus_test, mcid, gamma_sep, gamma_sep_cth}, ColumnTypes -> {Int_t, Int_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Float_t, Int_t, Int_t, Int_t, Int_t, Float_t[n_clus][5], Float_t[n_clus], Float_t[n_clus], Int_t[n_clus], UInt_t, UInt_t, Int_t[n_clus], Float_t, Float_t}}

•Cut Development

cutBits = GetColumnData["cuts", "", 10, 1, dataFile, treeName]

{542383, 540335, 645608, 527023, 645807, 524271, 645295, 541359, 583343, 580088}

IntegerDigits[#, 2, 20] & /@ cutBits // TableForm

1 0 0 0 0 1 0 0 0 1 1 0 1 0 1 0 1 1 1 1
1 0 0 0 0 0 1 1 1 1 1 0 1 0 1 0 1 1 1 1
1 0 0 1 1 1 0 1 1 0 0 1 1 1 1 0 1 0 0 0
1 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 1 1 1
1 0 0 1 1 1 0 1 1 0 1 0 1 0 1 0 1 1 1 1
0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1
1 0 0 1 1 1 0 1 1 0 0 0 1 0 1 0 1 1 1 1
1 0 0 0 0 1 0 0 0 0 1 0 1 0 1 0 1 1 1 1
1 0 0 0 1 1 1 0 0 1 1 0 1 0 1 0 1 1 1 1
1 0 0 0 1 1 0 1 1 0 0 1 1 1 1 1 1 0 0 0

Off[General :: "spell1"] ;

cutMask[cuts_List] := Module[{cutNames, hexPatterns, cutMasks},  cutNames = {"etot", "etotImb", "imb", "nClusTotLow", "nClusTotHigh", "nClusMagLow", "nClusMagHigh", "nClusEmLow", "nClusEmHigh", "rapidity", "clus1EM", "clus1HAD1", "clus1HAD2", "clus2EM", "clus2HAD1", "clus2HAD2", "eAngle", "pass", "passImb", "fail"} ;  hexPatterns = {1, 2, 4, 8, 10, 20, 40, 80, 100, 200, 400, 800, 1000, 2000, 4000, 8000, 10000, 20000, 40000, 80000} ;  cutMasks = Flatten[Extract[hexPatterns, Position[cutNames, #, {1}] & /@ cuts]] ;  cutMasks = ToExpression["16^^" <> ToString[#]] & /@ cutMasks ;  BitOr[Sequence @@ cutMasks]] ;

On[General :: "spell1"] ;

cuts = {"clus1EM", "clus1HAD1", "clus1HAD2", "clus2EM", "clus2HAD1", "clus2HAD2"} ;

cuts = {"etot", "imb"} ;

cuts = {"etotImb", "imb"} ;

cutMask[cuts]

6

IntegerDigits[cutMask[cuts], 2, 20]

{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0}

cutExpr[cuts_List] := "(cuts&" <> ToString[cutMask[cuts]] <> ")==" <> ToString[cutMask[cuts]] ;

cutExpr[{""}] := "" ;

cutExpr[cuts]

(cuts&6)==6

IntegerDigits[#, 2, 20] & /@ GetColumnData["cuts", cutExpr[cuts], 10, 1, dataFile, treeName] // TableForm

1 0 0 0 0 1 0 0 0 1 1 0 1 0 1 0 1 1 1 1
1 0 0 0 0 0 1 1 1 1 1 0 1 0 1 0 1 1 1 1
1 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 1 1 1
1 0 0 1 1 1 0 1 1 0 1 0 1 0 1 0 1 1 1 1
0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1
1 0 0 1 1 1 0 1 1 0 0 0 1 0 1 0 1 1 1 1
1 0 0 0 0 1 0 0 0 0 1 0 1 0 1 0 1 1 1 1
1 0 0 0 1 1 1 0 0 1 1 0 1 0 1 0 1 1 1 1

•Figures

GetColumnData["E", "", 10, 1, dataFile, treeName]

{{{4.939472675323486`, 6.731055736541748`, 3.0936279296875`, 0.7133087515830994`, 15.477465629577637`}, {2.6560821533203125`, 2.4121527671813965`, 0.822866678237915`, 0.977504551410675`, 6.868606090545654`}, {3.3508481979370117`, 1.5621953010559082`, 0.`, 0.`, 4.91304349899292`}}, {{9.084005355834961`, 13.21963119506836`, 0.10470519214868546`, 0.`, 22.408342361450195`}, {6.318926811218262`, 9.498512268066406`, 4.95521879196167`, 0.6522316336631775`, 21.424890518188477`}, {0.6722905039787292`, 0.2088964432477951`, 0.`, 0.`, 0.8811869621276855`}}, {{0.03941590338945389`, 0.06341053545475006`, 2.166457414627075`, 0.`, 2.2692837715148926`}, {0.03229059278964996`, 0.15580320358276367`, 0.`, 0.`, 0.18809379637241364`}, {0.0741484984755516`, 0.0949367955327034`, 0.`, 0.`, 0.169085294008255`}}, {{4.738259792327881`, 2.7880916595458984`, 2.5287609100341797`, 1.1745487451553345`, 11.229660987854004`}, {3.7309722900390625`, 2.1414082050323486`, 3.5518300533294678`, 0.7566192150115967`, 10.180830001831055`}, {0.9099555611610413`, 0.47797855734825134`, 0.`, 0.`, 1.3879340887069702`}}, {{4.930678367614746`, 0.9889340996742249`, 0.`, 0.`, 5.919612407684326`}, {2.484910011291504`, 0.863442063331604`, 0.`, 0.`, 3.3483521938323975`}, {2.6872787475585938`, 0.15140888094902039`, 0.`, 0.`, 2.8386876583099365`}}, {{16.04975128173828`, 10.11223030090332`, 0.`, 0.`, 26.1619815826416`}, {15.598451614379883`, 6.247125148773193`, 0.`, 0.`, 21.845577239990234`}, {0.18650849163532257`, 0.1008681058883667`, 0.`, 0.`, 0.28737661242485046`}}, {{3.646071434020996`, 5.010239601135254`, 1.2589768171310425`, 0.051975052803754807`, 9.967263221740723`}, {0.07778260111808777`, 3.3536179065704346`, 0.4981934428215027`, 0.`, 3.929594039916992`}, {1.0513628721237183`, 0.7102078795433044`, 0.21100319921970367`, 0.41823771595954895`, 2.3908116817474365`}}, {{0.24749501049518585`, 2.6332476139068604`, 3.2207119464874268`, 4.430299758911133`, 10.531754493713379`}, {2.400040864944458`, 2.6785645484924316`, 2.021249771118164`, 0.9512355923652649`, 8.051091194152832`}, {0.06621386855840683`, 0.12797848880290985`, 0.2028663009405136`, 1.5820884704589844`, 1.97914719581604`}}, {{3.1230297088623047`, 9.734668731689453`, 4.202474117279053`, 3.0969433784484863`, 20.157115936279297`}, {5.161961555480957`, 5.007111072540283`, 1.0850282907485962`, 0.23952098190784454`, 11.493622779846191`}, {2.0240190029144287`, 1.7025240659713745`, 0.08486746996641159`, 0.22577860951423645`, 4.037189483642578`}}, {{1.2803781032562256`, 0.3412148654460907`, 0.`, 0.`, 1.6215929985046387`}, {0.42072734236717224`, 0.5866355299949646`, 0.`, 0.`, 1.0073628425598145`}, {0.18654420971870422`, 0.0032257901038974524`, 0.`, 0.`, 0.18976999819278717`}}}

•Energy and Imbalance

cuts = {""} ;

rootData = GetColumnData["imb:etot", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

175564

Take[rootData, 10]

{{0.04443121328949928`, 43.58163070678711`}, {0.07033474743366241`, 50.85923767089844`}, {0.9925849437713623`, 3.130894899368286`}, {0.09371522068977356`, 33.988155364990234`}, {0.3970527648925781`, 25.255107879638672`}, {0.08816857635974884`, 49.15450668334961`}, {0.4075039029121399`, 28.143949508666992`}, {0.22438418865203857`, 26.47696876525879`}, {0.06541814655065536`, 43.069664001464844`}, {0.6391667723655701`, 3.0589261054992676`}}

Swap the etot and imb columns.

plotData = rootData ;

If[Length[plotData] > scatterPlotPoints, plotData = Take[plotData, scatterPlotPoints]] ;

ListPlot[plotData, PlotRange -> {{0, 1}, {0, 100}}, PlotLabel -> "Total Energy vs. Imbalance, no cuts", FrameLabel -> {"Imbalance", "Total Energy (GeV)"}, PlotStyle -> {PointSize[0.001]}, commonOptions] ;

[Graphics:HTMLFiles/index_69.gif]

cuts = {"nClusMagLow", "nClusMagHigh"} ;

rootData = GetColumnData["imb:etot", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

56333

plotData = rootData ;

If[Length[plotData] > scatterPlotPoints, plotData = Take[plotData, scatterPlotPoints]] ;

ListPlot[plotData, PlotRange -> {{0, 1}, {0, 100}}, PlotLabel -> "Total Energy vs. Imbalance, 2 <= n_clus <= 11", FrameLabel -> {"Imbalance", "Total Energy (GeV)"}, PlotStyle -> {PointSize[0.001]}, commonOptions] ;

[Graphics:HTMLFiles/index_77.gif]

•Number of Clusters per Event

cuts = {""} ;

cname = "n_clus_tot" ;

rootData = GetColumnData[cname, cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

175564

plotData = rootData ;

HistogramPlot[plotData, {101, 0, 100}, PlotLabel -> "n_clus Distribution, (" <> cname <> ")", FrameLabel -> {"number of clusters", "Counts"}] ;

[Graphics:HTMLFiles/index_85.gif]

cname = "n_clus_mag" ;

rootData = GetColumnData[cname, cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

175564

plotData = rootData ;

HistogramPlot[plotData, {61, 0, 60}, PlotLabel -> "n_clus Distribution, (" <> cname <> ")", FrameLabel -> {"number of clusters", "Counts"}] ;

[Graphics:HTMLFiles/index_92.gif]

cname = "n_clus_em" ;

rootData = GetColumnData[cname, cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

175564

plotData = rootData ;

HistogramPlot[plotData, {61, 0, 60}, PlotLabel -> "n_clus Distribution, (" <> cname <> ")", FrameLabel -> {"number of clusters", "Counts"}] ;

[Graphics:HTMLFiles/index_99.gif]

rootData = GetColumnData["n_clus_mag:n_clus_em", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

175564

plotData = Column[rootData, 1] - Column[rootData, 2] ;

HistogramPlot[plotData, {61, 0, 60}, PlotLabel -> "n_clus_mag-n_clus_em", FrameLabel -> {"number of clusters", "Counts"}] ;

[Graphics:HTMLFiles/index_105.gif]

•Cluster Energy Plots

makeClusCut[clusIndex_, cutIndex_] := Module[{clusCuts, cutList},  clusCuts = {"E[n][0]+E[n][1]>10", "E[n][2]<3", "E[n][3]<0.6"} ;  cutList = {StringReplace[clusCuts, {"n" -> "0"}]} ;  AppendTo[cutList, StringReplace[clusCuts, {"n" -> "1"}]] ;  cutList = Complement[Flatten[cutList], {Extract[cutList, {clusIndex, cutIndex}]}] ;  StringJoin[StringJoin[#, "&&"] & /@ Drop[cutList, -1], Last[cutList]]]

•Energy in EM1 + EM2 for cluster 1

Off[General :: "spell1"] ;

clusCut = makeClusCut[1, 1]

E[0][2]<3&&E[0][3]<0.6&&E[1][0]+E[1][1]>10&&E[1][2]<3&&E[1][3]<0.6

On[General :: "spell1"] ;

clus = GetColumnData["E[0][]", clusCut , -1, 1, dataFile, treeName] ;

Length[clus]

16288

Take[clus, 10] // TableForm

16.04975128173828` 10.11223030090332` 0.` 0.` 26.1619815826416`
10.579289436340332` 8.640105247497559` 0.2834550738334656` 0.16381382942199707` 19.666664123535156`
10.349469184875488` 16.95244598388672` 0.206232950091362` 0.` 27.508148193359375`
10.459217071533203` 15.173312187194824` 0.1465078592300415` 0.` 25.779037475585938`
11.994686126708984` 10.176566123962402` 0.2627420723438263` 0.2429988980293274` 22.67699432373047`
10.939254760742188` 16.58409309387207` 0.25368329882621765` 0.` 27.77703094482422`
13.439058303833008` 5.594483375549316` 0.` 0.` 19.03354263305664`
1.5562491416931152` 28.790822982788086` 1.8693290948867798` 0.` 32.216400146484375`
10.143742561340332` 21.25777244567871` 0.14396964013576508` 0.` 31.545486450195312`
8.284002304077148` 9.130632400512695` 1.2216001749038696` 0.25322532653808594` 18.88945960998535`

plotData = clus[[All, 1]] + clus[[All, 2]] ;

HistogramPlot[plotData, {100, 0, 50}, PlotLabel -> "EM Energy for cluster 1", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_117.gif]

•Energy in EM1 + EM2 for cluster 2

clusCut = makeClusCut[2, 1]

E[0][0]+E[0][1]>10&&E[0][2]<3&&E[0][3]<0.6&&E[1][2]<3&&E[1][3]<0.6

clus = GetColumnData["E[1][]", clusCut , -1, 1, dataFile, treeName] ;

Length[clus]

28038

plotData = clus[[All, 1]] + clus[[All, 2]] ;

HistogramPlot[plotData, {100, 0, 50}, PlotLabel -> "EM Energy for cluster 2", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_125.gif]

•Energy in HAD1 for cluster 1

clusCut = makeClusCut[1, 2]

E[0][0]+E[0][1]>10&&E[0][3]<0.6&&E[1][0]+E[1][1]>10&&E[1][2]<3&&E[1][3]<0.6

clus = GetColumnData["E[0][2]", clusCut , -1, 1, dataFile, treeName] ;

Length[clus]

16663

plotData = clus ;

HistogramLogPlot[plotData, {100, 0, 5}, PlotLabel -> "HAD1 Energy for cluster 1", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_133.gif]

•Energy in HAD1 for cluster 2

clusCut = makeClusCut[2, 2]

E[0][0]+E[0][1]>10&&E[0][2]<3&&E[0][3]<0.6&&E[1][0]+E[1][1]>10&&E[1][3]<0.6

clus = GetColumnData["E[1][2]", clusCut , -1, 1, dataFile, treeName] ;

Length[clus]

16488

plotData = clus ;

HistogramLogPlot[plotData, {100, 0, 5}, PlotLabel -> "HAD1 Energy for cluster 2", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_141.gif]

•Energy in HAD2 for cluster 1

clusCut = makeClusCut[1, 3]

E[0][0]+E[0][1]>10&&E[0][2]<3&&E[1][0]+E[1][1]>10&&E[1][2]<3&&E[1][3]<0.6

clus = GetColumnData["E[0][3]", clusCut , -1, 1, dataFile, treeName] ;

Length[clus]

17168

plotData = clus ;

HistogramLogPlot[plotData, {100, 0, 0.68}, PlotLabel -> "HAD2 Energy for cluster 1", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_149.gif]

•Energy in HAD2 for cluster 2

clusCut = makeClusCut[2, 3]

E[0][0]+E[0][1]>10&&E[0][2]<3&&E[0][3]<0.6&&E[1][0]+E[1][1]>10&&E[1][2]<3

clus = GetColumnData["E[1][3]", clusCut , -1, 1, dataFile, treeName] ;

Length[clus]

16880

plotData = clus ;

HistogramLogPlot[plotData, {100, 0, 0.68}, PlotLabel -> "HAD2 Energy for cluster 2", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_157.gif]

•Rapidity

cuts = {"etotImb", "imb", "nClusEmLow", "nClusEmHigh", "clus1EM", "clus1HAD1", "clus1HAD2", "clus2EM", "clus2HAD1", "clus2HAD2", "eAngle"} ;

rootData = GetColumnData["rapidity", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

12603

plotData = rootData ;

HistogramLogPlot[plotData, {100, -1, 1}, PlotLabel -> "Rapidity", FrameLabel -> {"Rapidity", "Counts"}] ;

[Graphics:HTMLFiles/index_164.gif]

•Cluster 1 Energy + Cluster 2 Energy vs. Thrust

cuts = {"etotImb", "imb", "nClusEmLow", "nClusEmHigh", "clus1EM", "clus1HAD1", "clus1HAD2", "clus2EM", "clus2HAD1", "clus2HAD2", "rapidity"} ;

rootData = GetColumnData["thrust2:E[][4]", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

13159

Take[rootData, 10]

{{0.8404231071472168`, {26.1619815826416`, 21.845577239990234`, 0.28737661242485046`}}, {0.9688884019851685`, {19.666664123535156`, 18.161758422851562`, 0.41486483812332153`}}, {0.9537937045097351`, {27.508148193359375`, 26.152626037597656`, 0.3294718861579895`}}, {0.8667163252830505`, {25.779037475585938`, 24.753442764282227`, 2.304373264312744`}}, {-0.9333095550537109`, {22.67699432373047`, 19.504348754882812`, 6.681295871734619`}}, {0.9597195386886597`, {27.77703094482422`, 17.49248504638672`, 0.48797523975372314`}}, {-0.04555215686559677`, {32.216400146484375`, 30.786670684814453`, 0.7356054782867432`}}, {-0.2079419195652008`, {31.545486450195312`, 29.16990852355957`}}, {0.8765984177589417`, {26.10801124572754`, 25.339513778686523`}}, {0.9439064860343933`, {25.619077682495117`, 25.616796493530273`, 1.2882150411605835`}}}

plotData = rootData /. {thrust_, {e1_, e2_, ___}} -> {Abs[thrust], e1 + e2} ;

If[Length[plotData] > scatterPlotPoints, plotData = Take[plotData, scatterPlotPoints]] ;

ListPlot[plotData, PlotRange -> {{0, 1}, {0, 80}}, PlotLabel -> "Energy for cluster 1 + cluster 2 vs. Thrust Angle", FrameLabel -> {"Abs[Cos[thrust]]", "Energy (GeV)"}, PlotStyle -> {PointSize[0.001]}, commonOptions] ;

[Graphics:HTMLFiles/index_174.gif]

•Total Event Energy vs. Thrust

cuts = {"etotImb", "imb"} ;

rootData = GetColumnData["thrust2:etot_imb", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

129232

plotData = rootData ;

If[Length[plotData] > scatterPlotPoints, plotData = Take[plotData, scatterPlotPoints]] ;

ListPlot[plotData, PlotRange -> {{0, 1}, {0, 80}}, PlotLabel -> "Total Event Energy vs. Thrust Angle", FrameLabel -> {"Abs[Cos[thrust]]", "Energy (GeV)"}, PlotStyle -> {PointSize[0.001]}, commonOptions] ;

[Graphics:HTMLFiles/index_182.gif]

cuts = {"etotImb", "imb", "nClusEmLow", "nClusEmHigh"} ;

rootData = GetColumnData["thrust2:etot_imb", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

18995

plotData = rootData ;

If[Length[plotData] > scatterPlotPoints, plotData = Take[plotData, scatterPlotPoints]] ;

ListPlot[plotData, PlotRange -> {{0, 1}, {0, 80}}, PlotLabel -> "Total Event Energy vs. Thrust Angle", FrameLabel -> {"Abs[Cos[thrust]]", "Energy (GeV)"}, PlotStyle -> {PointSize[0.001]}, commonOptions] ;

[Graphics:HTMLFiles/index_190.gif]

•Cos[θ] Distribution

cuts = {"pass"} ;

rootData = GetColumnData["thrust2", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

12461

plotData = Abs[rootData] ;

HistogramPlot[plotData, {19, 0, 0.95}, PlotLabel -> "number of events vs. Thrust Angle", FrameLabel -> {"Abs[Cos[thrust]]", "Counts"}] ;

[Graphics:HTMLFiles/index_197.gif]

•Polarization

cuts = {""} ;

rootData = GetColumnData["epol", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

175564

plotData = rootData ;

HistogramPlot[plotData, {100, -1, 1}, PlotLabel -> "e Polarization", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_204.gif]

cuts = {"pass"} ;

rootData = GetColumnData["epol", cutExpr[cuts], -1, 1, dataFile, treeName] ;

Length[rootData]

12461

plotData = rootData ;

HistogramPlot[plotData, {100, -1, 1}, PlotLabel -> "e Polarization", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_211.gif]

HistogramPlot[plotData, {100, -.85, -.4}, PlotLabel -> "e Polarization", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_213.gif]

HistogramPlot[plotData, {100, .4, .85}, PlotLabel -> "e Polarization", FrameLabel -> {"Energy (GeV)", "Counts"}] ;

[Graphics:HTMLFiles/index_215.gif]


Converted by Mathematica  (January 2, 2003)