Thinking global, living local

How to use FCI-warehouse-MSPvsMSV: grain procurement, MSP and mandi-price data with working models

October 19, 2026

A research and data repository on India's foodgrain procurement: the MSP series, mandi prices against MSP, FCI stocks and storage, a dashboard, and small Python models for holding economics and grain processing.

Open-Source Tools · How-To · Policy analysis

How to use FCI-warehouse-MSPvsMSV: grain procurement, MSP and mandi-price data with working models

Skip to article content
Text Size

Revised · v1.0.0 · what changed

14crops in the MSP series, 2010-11 onward
16crops in the mandi-vs-MSP comparison (23 Jul 2026)
17,247mandi records behind that comparison
16commodities in the holding-economics model, all negative net of carry

Code: github.com/herrrickshaw/FCI-warehouse-MSPvsMSV

Watch the walkthrough

Watch on YouTube: youtu.be/KdOY3vWwzuM

Why it is useful

  • Agricultural-policy analysts, journalists and students asking 'does MSP actually hold in the market?' get a ready table of mandi modal prices against MSP, crop by crop, with sources recorded in a manifest.
  • It replaces stitching together CACP, Agmarknet, DFPD bulletins and FCI data by hand. The data/ folder holds 49 CSVs, and data/MANIFEST.md says where each came from and what is missing.
  • Evidence from the run: the mandi table shows 92% of bajra and 84% of moong market reports below MSP on 23 July 2026, against 19% for wheat. Two models also ran unchanged in a fresh environment.
  • The holding-economics model produced a clear result: for every commodity tested, estimated storage and financing cost exceeded price appreciation over 12, 24 and 36 months, which bears directly on the 'why not buy and hold' question behind MSV.

What it is for

FCI-warehouse-MSPvsMSV evaluates whether a Minimum Support Volume guarantee could extend effective price support beyond rice and wheat. It contains cited reports (report/), CSV data with a provenance manifest (data/), a self-contained HTML dashboard (dashboard/), a Colab notebook, and several Python models: holding economics, OMSS grain-processing unit economics, rice-bran oil savings, and a real farm income index.

This post uses the MSP series, the mandi-vs-MSP table and the two models that ran cleanly.

Who it is for

  • Agricultural-economics students and researchers
  • Journalists covering procurement, MSP and food stocks
  • Policy teams comparing price-support designs
  • Developers wanting a worked, sourced Indian agri dataset
Not for.
  • Investment or trading advice: this is not investment advice
  • Official statistics: figures are compiled from published sources and not audited
  • Farm-level decisions: models are stylised unit economics, not forecasts

What you need

RequirementWhyHow to get it
Python 3 with pandas and numpyholding_economics.py uses both; the processing model needs neitherpip install pandas numpy
gitTo clonePre-installed on most systems
A web browserTo open dashboard/index.htmlAny modern browser

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/FCI-warehouse-MSPvsMSV.git
cd FCI-warehouse-MSPvsMSV
claude      # or: gemini

Install

  1. Clone the repository
    git clone https://github.com/herrrickshaw/FCI-warehouse-MSPvsMSV.git
    cd FCI-warehouse-MSPvsMSV
  2. Create an environment and install dependencies
    python3 -m venv .venv && source .venv/bin/activate
    pip install pandas numpy

Quick start: commands and what you should see

View the MSP vs mandi table

cat data/mandi_vs_msp_20260723.csv

16 crops with MSP, number of market reports, median modal price, share of reports below MSP and median gap.

Run the grain-processing unit-economics model

cd data && python3 omss_processing_model.py

EBITDA per quintal for wheat-to-atta and paddy-to-rice, plus a 300 TPD flour-mill scale case.

Run the holding-economics model

cd data && python3 holding_economics.py

Summary, horizon-return and post-crash-episode tables per commodity; it rewrites three CSVs next to the script, so run it in a copy if you want the repo untouched.

Sample outputs

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

MSP vs mandi sample table (data/mandi_vs_msp_20260723.csv)

crop     MSP 2025-26  market reports  modal median  % reports below MSP  median gap vs MSP
wheat        2425           768         2500.0          19                 +3%
paddy        2369           335         2385.0          36                 +1%
gram         5650           231         5900.0          22                 +4%
maize        2400           226         2200.0          75                 -8%
soybean      5328           195         7050.0           2                +32%
moong        8768           161         6901.0          84                -21%
tur          8000           129         7531.0          70                 -6%
bajra        2775            84         2382.0          92                -14%
ragi         4886            14         3550.0          93                -27%

Prices in Rs per quintal. Trimmed from 16 crops. Built from the 23 July 2026 Agmarknet daily feed (17,247 records) per MANIFEST.md. Crops with few reports (ragi 14, sunflower 2) are thin evidence.

Holding economics (14-year window, % per year)

commodity   price CAGR  carry cost  net annual  verdict
paddy             4.84       20.33      -15.48  CARRY EXCEEDS APPRECIATION
wheat             5.19       16.99      -11.80  CARRY EXCEEDS APPRECIATION
maize             3.81       18.50      -14.69  CARRY EXCEEDS APPRECIATION
arhar_tur         5.74       13.67       -7.93  CARRY EXCEEDS APPRECIATION
sugar             2.33       16.59      -14.26  CARRY EXCEEDS APPRECIATION

Rows trimmed; all 16 commodities show the same verdict. Carry costs combine storage tariffs and financing assumptions that are cited in the repo's report, not in this output.

Grain-processing unit economics

python3 omss_processing_model.py
WHEAT->ATTA OMSS-sourced: grain 2550 | revenue 2926 | gross 376 | EBITDA 196/qtl (6.7% margin)
WHEAT->ATTA mandi-sourced: grain 2500 | revenue 2926 | gross 426 | EBITDA 246/qtl (8.4% margin)
PADDY->RICE open-market: paddy 2385 | revenue 2520 | EBITDA -15/qtl (-0.6% margin)
SCALE: 300 TPD flour mill | EBITDA Rs 17.6 cr | capital employed ~Rs 80 cr | ROCE ~22%

Deterministic model with labelled input assumptions, not a forecast.

Ways to use it

MethodHow it works
Open the dashboarddashboard/index.html is self-contained; open it in a browser (add ?theme=dark for dark mode).
Query the CSVsLoad msp_series.csv, procurement_by_year.csv or stocks_vs_norms.csv in pandas or DuckDB.
Colab notebookThe README links a Colab notebook that reproduces the charts.
Through an AI assistantOpen the clone in Claude Code or Gemini CLI, or upload README.md, MANIFEST.md and a CSV to a chat assistant.

Sample prompts for your AI assistant

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

  • Read data/MANIFEST.md and list which datasets cover procurement, stocks, storage and prices, with their known gaps.
  • Using data/msp_series.csv, compute the MSP CAGR for wheat and paddy since 2010-11 and chart both.
  • From mandi_vs_msp_20260723.csv, which crops have more than half of market reports below MSP? Why might the sample sizes matter?
  • Explain the assumptions in holding_economics.py and which one the verdict is most sensitive to.
  • Summarise the case for and against a Minimum Support Volume from report/msp-vs-msv-main-report.md in 200 words.

Limits and honest caveats

  • Not investment advice. Figures are compiled from public sources and unaudited.
  • Year labels differ between files. In msp_series.csv the year is the sowing year, so the rabi wheat MSP of Rs 2,425 sits under 2024-25 and Rs 2,585 under 2025-26, whereas mandi_vs_msp_20260723.csv uses the marketing-year MSP (wheat Rs 2,425 for 2025-26). Check the label before joining the two.
  • The mandi comparison is one day (23 July 2026) and includes crops with very few reports.
  • The holding-economics verdict depends on assumed carry rates (storage tariffs and financing) and WPI price series; it is not a forecast. Running it rewrites its three output CSVs.
  • The repo includes some company financials taken from screener.in; I did not use or reproduce them, and you should check licensing before reusing that file.
  • I did not run the other models (biodiesel, RBO savings, farm income index) or the dashboard, and the mandi data's upstream collection was not re-run.

Sources: the FCI-warehouse-MSPvsMSV README, data/MANIFEST.md, data/msp_series.csv, data/mandi_vs_msp_20260723.csv and the Python models; omss_processing_model.py and holding_economics.py run on 19 October 2026 on a copy of the data folder (latest commit 3 October 2026).

Revision history.
  • v1.0.0 — 19 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.