Changeset a9d423d in git
- Timestamp:
- Jul 9, 2013, 10:09:55 PM (11 years ago)
- Branches:
- ImprovedOutputFile, Timing, dual_readout, llp, master
- Children:
- 78844a1
- Parents:
- 405a724
- Location:
- examples
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
examples/MemoryUsage.C
r405a724 ra9d423d 12 12 13 13 TGraph grvsz, grrss; 14 TLegend legend(0.41, 0.58, 0.77, 0.67); 15 16 TCanvas *canvas; 14 17 15 18 //------------------------------------------------------------------------------ … … 72 75 canvas = new TCanvas("c1", "c1", 800, 650); 73 76 } 74 canvas->Set Logy(0);77 canvas->SetGrid(); 75 78 canvas->SetHighLightColor(kExRootBackgroundColor); 76 79 … … 102 105 grvsz.Draw("AL"); 103 106 grrss.Draw("L"); 107 108 legend.SetTextSize(kExRootFontSize); 109 legend.SetTextFont(kExRootFont); 110 legend.SetFillColor(kExRootBackgroundColor); 111 legend.SetBorderSize(0); 112 legend.AddEntry(&grvsz, "virtual memory size", "l"); 113 legend.AddEntry(&grrss, "resident set size", "l"); 114 legend.Draw(); 104 115 } 105 116 -
examples/ProcessingTime.C
r405a724 ra9d423d 3 3 */ 4 4 5 static const Font_t kExRootFont = 42; 6 static const Float_t kExRootFontSize = 0.04; 7 static const Color_t kExRootBackgroundColor = 10; 8 5 9 //------------------------------------------------------------------------------ 6 10 7 11 TGraphErrors gr; 12 13 TCanvas *canvas; 8 14 9 15 //------------------------------------------------------------------------------ … … 17 23 Int_t i; 18 24 25 TDirectory *currentDirectory = gDirectory; 26 27 // Graphics style parameters to avoid grey background on figures 28 gStyle->SetCanvasColor(kExRootBackgroundColor); 29 gStyle->SetStatColor(kExRootBackgroundColor); 30 // gStyle->SetTitleColor(kExRootBackgroundColor); 31 gStyle->SetPadColor(kExRootBackgroundColor); 32 33 gStyle->SetPadTopMargin(0.10); 34 gStyle->SetPadRightMargin(0.10); 35 gStyle->SetPadBottomMargin(0.15); 36 gStyle->SetPadLeftMargin(0.15); 37 38 gStyle->SetStatFont(kExRootFont); 39 gStyle->SetStatFontSize(kExRootFontSize); 40 41 gStyle->SetTitleFont(kExRootFont, ""); 42 gStyle->SetTitleFont(kExRootFont, "X"); 43 gStyle->SetTitleFont(kExRootFont, "Y"); 44 gStyle->SetTitleFont(kExRootFont, "Z"); 45 gStyle->SetTitleSize(kExRootFontSize, ""); 46 gStyle->SetTitleSize(kExRootFontSize, "X"); 47 gStyle->SetTitleSize(kExRootFontSize, "Y"); 48 gStyle->SetTitleSize(kExRootFontSize, "Z"); 49 50 gStyle->SetLabelFont(kExRootFont, "X"); 51 gStyle->SetLabelFont(kExRootFont, "Y"); 52 gStyle->SetLabelFont(kExRootFont, "Z"); 53 gStyle->SetLabelSize(kExRootFontSize, "X"); 54 gStyle->SetLabelSize(kExRootFontSize, "Y"); 55 gStyle->SetLabelSize(kExRootFontSize, "Z"); 56 57 gStyle->SetPadTickX(1); 58 gStyle->SetPadTickY(1); 59 60 gStyle->SetTextFont(kExRootFont); 61 gStyle->SetTextSize(kExRootFontSize); 62 63 gStyle->SetOptStat(111110); 64 // gStyle->SetOptFit(101); 65 66 canvas = static_cast<TCanvas*>(gROOT->FindObject("c1")); 67 if(canvas) 68 { 69 canvas->Clear(); 70 canvas->UseCurrentStyle(); 71 canvas->SetWindowSize(800, 650); 72 } 73 else 74 { 75 canvas = new TCanvas("c1", "c1", 800, 650); 76 } 77 canvas->SetGrid(); 78 canvas->SetHighLightColor(kExRootBackgroundColor); 79 80 currentDirectory->cd(); 81 19 82 for(i = 1; i < 8; ++i) 20 83 { … … 25 88 26 89 gr.GetXaxis()->SetLimits(1.0, 9.0); 90 gr.GetXaxis()->SetTitleOffset(1.5); 91 gr.GetYaxis()->SetTitleOffset(1.75); 27 92 gr.GetXaxis()->SetTitle("number of jets"); 28 93 gr.GetYaxis()->SetTitle("processing time per event, ms");
Note:
See TracChangeset
for help on using the changeset viewer.