Link to ROOT Class Index

Links

Example Code

Generate Working Class Dictionary

  • Location: mwlebour@bourge:~/work/cms/surfturf/pass2/rootTest

Generic Useful Info

gROOT

  • gROOT->LoadMacro(const char * filename)
    • Equivalent to .L filename

Useful Histogramming Options

gStyle Commands

void SetOptFit(Int_t mode)

  • mode = pcev (default = 0111)
    • p - Probability
    • c - Chisquare/Number of degress of freedom
    • e - Errors (if e=1, v must be 1)
    • v - Name/values of parameters

void SetOptStat(Int_t mode)

  • mode = ksiourmen (default = 000001111)
    • k = 1; kurtosis printed
    • k = 2; kurtosis and kurtosis error printed
    • s = 1; skewness printed
    • s = 2; skewness and skewness error printed
    • i = 1; integral of bins printed
    • o = 1; number of overflows printed
    • u = 1; number of underflows printed
    • r = 1; rms printed
    • r = 2; rms and rms error printed
    • m = 1; mean value printed
    • m = 2; mean and mean error values printed
    • e = 1; number of entries printed
    • n = 1; name of histogram is printed

void SetLabelSize(Float_t size, Option_t *axis)

  • size is expressed as % of pad height
  • axis is "x" or "xyz" etc...

void SetFrameFillColor(Color_t color=1)

  • sets default fill color for frames (i.e. inside of axes)

void SetTitleX(Float_t x=0)

  • also works for SetTitleY, where x is expressed as % of pad width

TCanvas Options

TAttAxis?

  • SetTitleOffset(1.4);

TPad Options

  • SetLeftMargin(0.15)

TH1 Options

  • void SetLineColor(Color_t lcolor)
  • void SetMarkerColor(Color_t tcolor=1)
  • void SetMarkerStyle(Style_t mstyle=1)

markers.gif

  • void SetMarkerSize(Size_t msize=1)
  • void SetLineStyle(Style_t lstyle)

userlinestyle.gif

  • void SetLineWidth(Width_t lwidth)

Color Information

table.gif

Only in 5.15

wheel.gif

Determine ROOT version @ compile time:

  • #if ROOT_VERSION_CODE <= ROOT_VERSION(5,15,0)

-- MatthewLeBourgeois - 18 Apr 2007

Topic attachments
I Attachment Action Size Date Who Comment
gifgif markers.gif manage 3.0 K 2007/04/20 - 01:34 MatthewLeBourgeois  
gifgif table.gif manage 10.5 K 2007/04/20 - 00:55 MatthewLeBourgeois  
gifgif userlinestyle.gif manage 2.9 K 2007/04/20 - 01:35 MatthewLeBourgeois  
gifgif wheel.gif manage 30.7 K 2007/04/20 - 00:48 MatthewLeBourgeois  
Topic revision: r8 - 2009/02/25 - 18:56:50 - RyanKelley
 
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback