vepadulano / PyRDF

Python Library for doing ROOT RDataFrame analysis
https://pyrdf.readthedocs.io/en/latest/
9 stars 7 forks source link
screen shot 2018-07-06 at 8 25 59 pm

PyRDF : The Python ROOT DataFrame Library

Build Status Documentation Status

A pythonic wrapper around ROOT's RDataFrame with support for distributed execution.

Sample usage

import PyRDF, ROOT
PyRDF.use('spark', {'npartitions':4})

df = PyRDF.RDataFrame("data", ['https://root.cern/files/teaching/CMS_Open_Dataset.root',])

etaCutStr = "fabs(eta1) < 2.3"
df_f = df.Filter(etaCutStr)

df_histogram = df_f.Histo1D("eta1")

canvas = ROOT.TCanvas()
df_histogram.Draw()
canvas.Draw()

Help and Support

Report

http://shravanmurali.com/PyRDF/