How to use pyroofit - 10 common examples

To help you get started, we’ve selected a few pyroofit examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github simonUU / PyrooFit / tests / test_pdf.py View on Github external
def test_fit():
    import ROOT
    x = ROOT.RooRealVar('mbc', '', 0, 0, 1)
    pdf = Gauss(x)
    df = get_test_df(100)
    pdf.fit(df)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_pdf.py View on Github external
def test_fit_bins():
    import ROOT
    x = ROOT.RooRealVar('mbc', '', 0, 0, 1)
    pdf = Gauss(x)
    df = get_test_df(100)
    pdf.fit(df, nbins=5)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_composites.py View on Github external
def test_AddPdf():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    bkg = Chebychev(('mbc', 0, 1))
    sig = Gauss(('mbc', 0, 1))

    pdf = sig+bkg

    #pdf.fit(df)
    #pdf.plot('test2.pdf')

    assert isinstance(pdf, AddPdf)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_composites.py View on Github external
def test_AddPdf_fit():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    bkg = Chebychev(('mbc', 0, 1))
    sig = Gauss(('mbc', 0, 1))

    pdf = sig+bkg

    pdf.fit(df)
    #pdf.plot('test2.pdf')

    assert isinstance(pdf, AddPdf)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_composites.py View on Github external
def test_AddPdf_fit():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    bkg = Chebychev(('mbc', 0, 1))
    sig = Gauss(('mbc', 0, 1))

    pdf = sig+bkg

    pdf.fit(df)
    #pdf.plot('test2.pdf')

    assert isinstance(pdf, AddPdf)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_models.py View on Github external
def test_Chebychev():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    pdf = Chebychev(('mbc', 0, 1))
    pdf.fix(True)
    #pdf.fit(df)
    #pdf.plot('test.pdf')
    pdf.observables.mbc # test that mbc is available by attribute lookup
    assert isinstance(pdf.roo_pdf, ROOT.RooChebychev)
github simonUU / PyrooFit / tests / test_composites.py View on Github external
def test_AddPdf():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    bkg = Chebychev(('mbc', 0, 1))
    sig = Gauss(('mbc', 0, 1))

    pdf = sig+bkg

    #pdf.fit(df)
    #pdf.plot('test2.pdf')

    assert isinstance(pdf, AddPdf)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_composites.py View on Github external
def test_AddPdf():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    bkg = Chebychev(('mbc', 0, 1))
    sig = Gauss(('mbc', 0, 1))

    pdf = sig+bkg

    #pdf.fit(df)
    #pdf.plot('test2.pdf')

    assert isinstance(pdf, AddPdf)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_composites.py View on Github external
def test_AddPdf_fit():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    bkg = Chebychev(('mbc', 0, 1))
    sig = Gauss(('mbc', 0, 1))

    pdf = sig+bkg

    pdf.fit(df)
    #pdf.plot('test2.pdf')

    assert isinstance(pdf, AddPdf)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)
github simonUU / PyrooFit / tests / test_composites.py View on Github external
def test_Convolution():
    import ROOT
    df = get_test_df()
    assert isinstance(df, pd.DataFrame)
    bkg = Chebychev(('mbc', 0, 1))
    sig = Gauss(('mbc', 0, 1))

    pdf = Convolution(bkg, sig)

    assert isinstance(pdf, Convolution)
    assert isinstance(pdf.roo_pdf, ROOT.RooAbsPdf)

pyroofit

Python wrapper for RooFit to create fits easily with pandas DataFrames.

MIT
Latest version published 4 years ago

Package Health Score

39 / 100
Full package analysis

Similar packages