Example #1
0
def LineColor(color):
    r"""The `color` argument doesn't necessarily have to be a ROOT color enum value, like `ROOT.kRed`.
    Here is what you can also do in PyROOT:

      1. Pass a string with the enum value name instead, e.g.:
    ~~~ {.py}
    pdf.plotOn(frame, LineColor="kRed")
    ~~~
      2. Pass a string with the corresponding single-character color code following the matplotlib convention:
    ~~~ {.py}
    pdf.plotOn(frame, LineColor="r")
    ~~~
      3. Pass a string with the enum value name instead followed by some manipulation of the enum value:
    ~~~ {.py}
    pdf.plotOn(frame, LineColor="kRed+1")
    ~~~
    """
    from cppyy.gbl import RooFit

    return RooFit._LineColor(_string_to_root_attribute(color, _color_map))
Example #2
0
def LineColor(color):
    # Redefinition of `LineColor` for matplotlib conventions and string arguments.
    from cppyy.gbl import RooFit

    return RooFit._LineColor(_string_to_root_attribute(color, _color_map))