VertiStratInsights Main website ↗

How to use ppac-ready-reckoner-data: load India's petroleum statistics as 100 ready CSV tables

Monday, October 19, 2026

The tables of PPAC's Ready Reckoner for FY2025-26 H1 (refining margins, ethanol blending, fuel sales, pipelines and more) extracted from PDF into 100 CSV files, plus the extraction script. This post loads them and shows what to clean.

Open-Source Tools · How-To · Energy & fuels models

How to use ppac-ready-reckoner-data: load India's petroleum statistics as 100 ready CSV tables

Skip to article content
Text Size

Revised · v1.0.0 · what changed

100CSV tables, all flagged ok in index.csv
3,465rows across all tables
904.80 Cr Lethanol received under EBP, Nov 2024 to Sep 2025
19.2%average blending, same period

Code: github.com/herrrickshaw/ppac-ready-reckoner-data

Watch the walkthrough

Watch on YouTube: youtu.be/nL78kDD0QSQ

Why it is useful

  • Energy analysts, students and journalists skip the PDF copy-paste: refining, gas, ethanol and sales tables are already CSV.
  • It replaces manual retyping of PPAC's Ready Reckoner, and the extraction script (extract_rr.py) can be pointed at the next edition.
  • The tables cover Table 1.1 economy indicators through Table 6.10 ethanol blending, including gross refining margins by refinery and state-wise fuel sales.
  • Evidence from the run: all 100 CSVs loaded in pandas (3,465 rows). It also surfaced real clean-up work: spaces stripped from state names, '**' markers for missing values, Indian-style numbers like 13,61,343, and one shifted Grand Total row.

What it is for

The repo holds the tables of the PPAC Ready Reckoner (annual, FY2025-26 H1 edition) as CSVs under annual_fy2025-26_h1/csv/, with index.csv mapping each file to its table number, caption and page. extract_rr.py rebuilds the CSVs from a Ready Reckoner PDF using pdfplumber.

The tables are the publisher's figures as printed; this repo extracts them but does not correct them.

Who it is for

  • Energy and fuels analysts who need Indian refining, gas, ethanol and sales data in tabular form
  • Students building dashboards or models on public petroleum statistics
  • Researchers who want a starting point for extracting the next Ready Reckoner edition
Not for.
  • Treating the CSVs as audited: they are machine-extracted from a PDF and need checking against the source before publication
  • Trading or investment decisions. This is not investment advice
  • Ready-to-chart numbers: most tables need cleaning first (see limits)

What you need

RequirementWhyHow to get it
Python 3.9+ and pandasTo load and clean the CSVspip install pandas
pdfplumber (only to re-extract)extract_rr.py uses it; the PDF itself is not in the repopip install pdfplumber; not run in this post
gitTo clone the repo (about 716 KB)git-scm.com

Get the code and an AI assistant

You do not have to be a programmer. Get the repository, give it to an AI assistant, and ask in plain language. Any of these routes works:

ToolWhat you needBest for
GitHubFree account to fork or star; git to clone, or the green Code button, then Download ZIP, or open in CodespacesGetting the code and keeping up with updates
Claude CodeClaude subscription or API key; run claude inside the cloned folderLetting the AI read and run the whole repo
Gemini CLIGoogle account; run gemini inside the cloned folderThe same hands-on workflow with Gemini
Claude.ai, Gemini or ChatGPT in the browserA chat account; upload README.md and the files you care about (or paste the output of git ls-files)Understanding the project and asking questions without installing anything
Other tools (Copilot Chat, Cursor, Codex CLI)Open the cloned folder in the tool and point it at README.md firstEditing and extending the code
git clone https://github.com/herrrickshaw/ppac-ready-reckoner-data.git
cd ppac-ready-reckoner-data
claude      # or: gemini

Install

  1. Clone the repository
    git clone https://github.com/herrrickshaw/ppac-ready-reckoner-data.git
    cd ppac-ready-reckoner-data
  2. Install pandas in a virtual environment
    python3 -m venv .venv && source .venv/bin/activate
    pip install pandas

Quick start: commands and what you should see

Load every table and count rows

python3 -c "import pandas as pd,glob;fs=sorted(glob.glob('annual_fy2025-26_h1/csv/*.csv'));print(len(fs),sum(len(pd.read_csv(f,header=None,dtype=str)) for f in fs))"

100 3465

Read one table (gross refining margins)

python3 -c "import pandas as pd;print(pd.read_csv('annual_fy2025-26_h1/csv/Table_4.7_grossrefiningmargins_grm_ofrefineries.csv',skiprows=2).head(8))"

Refiners by row and financial years by column, with $/bbl values (see sample output).

Sample outputs

Real output from a run on the date shown in the sources line; trimmed to fit.

Table 4.7 Gross refining margins ($/bbl), first rows (run 19 October 2026)

pd.read_csv('Table_4.7_grossrefiningmargins_grm_ofrefineries.csv', skiprows=2).head(8)
      Company  2020- 21  2021- 22 2022- 23 2023- 24 2024- 25 2024-25 (Q1) 2025-26 (Q1)
PSUrefineries       NaN       NaN      NaN      NaN      NaN          NaN          NaN
        IOCL#      5.64     11.25    19.52    12.05     4.80         6.39         2.15
        BPCL       4.06      9.09    20.24    14.14     6.82         7.86         4.88
        HPCL       3.86      7.19    12.09     9.08     5.74         5.03         3.08
        CPCL       7.14      8.85    12.48     8.64     4.22         6.33         3.22
        MRPL       3.71      8.72     9.88    10.36     4.45         4.70         3.88
        NRL#       37.23     43.46    35.82    29.72    19.95        21.50        21.41
        BORL       6.20     11.00       **       **       **           **           **

Values as extracted; '#' and '**' are the source's footnote markers (meaning is in the PDF). NRL's much higher figures are as printed in the extract; check the source footnote before using them.

Table 6.10 Ethanol blending programme, first rows

pd.read_csv('Table_6.10_ethanol_blending_programme.csv', skiprows=3, header=None, names=[...])
sr  state              qty_2425_cr_l  blend_2425  qty_2324_cr_l  blend_2324
 1  AndhraPradesh              40.84       19.3%          29.30       14.3%
 2  Andaman&Nicobar             0.00        7.2%           0.28        7.2%
 4  Assam                      29.03       19.2%          12.51       15.2%
11  Gujarat                    43.02       19.2%          39.57       14.3%
12  Haryana                    39.60       19.5%          25.98       14.8%
36  WestBengal                 35.01       19.5%          26.07       15.1%
    GrandTotal                   NaN      904.80          19.2%      707.40  (shifted)

Two extraction artefacts are visible: state names lost their spaces, and the Grand Total row is shifted one column to the right. Period 1 Nov 2024 to 30 Sep 2025 for the 2024-25 columns.

Table 1.1 Selected indicators (raw header and first rows)

head -6 Table_1.1_selected_indicators_of_the_indian_economy.csv
Table 1.1 : Selected indicators of the Indian economy,,,,,,,,,
General,,,,,,,,,
Sl. no.,Particulars,Source,Unit/ Base,2020-21,2021-22,2022-23,2023-24,2024-25,2025-26 (H1)
1,Projected Total Population ...,Report of the Technical Group ...,('000),"13,61,343","13,73,761",...
2,GDP,MoSPI,Rs Crores,"1,36,94,869","1,50,21,846",...,"47,89,000 (Q1)"
,GDP Growth,MoC&I,Growth %,-5.8,9.7,7.6,9.2,6.5,7.8 (Q1)

Titles and numbers carry Indian digit grouping and annotation suffixes like '(Q1)'; strip them before converting to numbers. Text trimmed with '...'.

Ways to use it

MethodHow it works
pandas / spreadsheetOpen any CSV, skip the caption rows, clean the number formats, and chart.
Index-driven loadingUse annual_fy2025-26_h1/index.csv to find a table by number or caption.
Re-extract a new editionpython3 extract_rr.py <ready_reckoner.pdf> <out_subdir> (needs pdfplumber and the PDF; not run here).
Through an AI assistantAsk an assistant to write a cleaning function that standardises these tables.

Sample prompts for your AI assistant

Copy, paste and edit the parts in [brackets].

  • Load annual_fy2025-26_h1/index.csv and list the tables about ethanol, with their file names.
  • Write a pandas function that cleans Indian-style numbers like '13,61,343' and values such as '47,89,000 (Q1)' and '**' into floats or NaN.
  • Fix the Table 6.10 Grand Total row that is shifted one column, and add the space back into state names.
  • Plot gross refining margins by refinery for 2020-21 to 2024-25 from Table 4.7, and flag values marked with ** or #.
  • Read extract_rr.py and explain how it finds table captions and joins wrapped header cells.

Limits and honest caveats

  • The repo README is only a banner pointing to the AI how-to; this post is based on the files, the script's docstring and the run.
  • The extraction script was not run: it needs the Ready Reckoner PDF (not in the repo) and pdfplumber.
  • The CSVs are machine-extracted from PDF. Seen in this run: spaces stripped from some text, a shifted Grand Total row in Table 6.10, '**' and '#' source markers, and long footnotes landing in data rows. Verify against the original PDF.
  • Figures are the publisher's as printed; the repo does not validate them. The PPAC licence terms were not found in the repo, so check PPAC's reuse terms before republishing.
  • Edition covered: FY2025-26 H1 only. Not investment advice.

Sources: the ppac-ready-reckoner-data repo (index.csv, 100 CSVs, extract_rr.py docstring), loaded with pandas in a throwaway virtualenv on 19 October 2026 from a fresh clone.

Revision history.
  • v1.0.0 — 29 October 2026 — first published.

About this article: Researched, written and edited by Umashankar Triplicane Dwarakanathan, with AI research assistance; every figure is meant to trace to the primary source cited. See the Editorial Policy for how sourcing, AI use and corrections work.

Umashankar Triplicane Dwarakanathan
Contact Us
Umashankar Triplicane Dwarakanathan
Investment Promotion & Energy-Sector Leader · Chennai, Tamil Nadu, India
LinkedIn → GitHub → Email +91 78273 81696
How this site works

Data-led analysis of India's trade, currency and industrial policy. Every article is built from primary official sources, and every figure links back to the release, table or filing it came from.

Sources. DGCI&S TradeStat (imports/exports, HSN-wise) · PIB (government press releases, January 2017 to today, refreshed daily) · RBI (circulars, balance of payments) · MoSPI (CPI/WPI, IIP) · PARIVESH (environmental clearances) · CCIL (bond yields) · BIS (policy rates) · SEBI, NSE/BSE and SEC filings for company data.

Interpretation. Figures carry their vintage and retrieval date; estimates and press-reported numbers are labelled as such; where sources disagree, both are shown. Corrections are made visibly, never silently. Articles are written with AI assistance from the cited sources — AI-generated text can misstate figures even when working from real material, so verify any number that matters to a decision against the linked primary source.

footer

Browse all articles by topic

Every piece on this blog, grouped. Or read the full index.

Agriculture & FertilisersAI ToolsChemicalsClimate & CarbonEnergy & FuelsGas & LNGImport SubstitutionIndustrial PolicyMarkets & FinanceMobility & EVPrices & InflationTextilesTrade & Tariffs

Each topic is a live archive page that updates itself as pieces are labelled. It replaces a hand-kept list that had fallen 18 articles behind.