scikit-hep / root_pandas

A Python module for conveniently loading/saving ROOT files as pandas DataFrames
MIT License
109 stars 35 forks source link

add __len__ method to read_root with chunks #75

Closed pseyfert closed 6 years ago

pseyfert commented 6 years ago

This allows usage in progress bars, such as tqdm

for chunk in tqdm(read_root("filename.root", chunksize=100)):
    do_something(chunk)
coveralls commented 6 years ago

Coverage Status

Coverage increased (+0.2%) to 84.058% when pulling 378b64a82fb41bfd022e8482129ad95c7029b76e on pseyfert:progressbar into bf6b624e2e647e7f7efd8823d7515d896afa17ed on scikit-hep:master.

chrisburr commented 6 years ago

Great idea! Thanks 👍

eduardo-rodrigues commented 5 years ago

Hi @pseyfert and @chrisburr, may I suggest that you add an example usage to the README file?