| Status | Description |
|---|---|
| PyPI | |
| GitHub | |
| Codecov | |
| Read the Docs | |
| PePy | |
| License |
BharatFinTrack is a Python package designed to simplify the process of downloading and analyzing financial data from India. Conceptualized on September 1, 2024, and launched on September 8, 2024, this package is tailored for long-term investors seeking to streamline their financial data workflows. The package focuses on open-source financial data, with an initial emphasis on analyzing Nifty Equity Indices. However, it is important to note that the package does not include features for technical indicators or real-time trading. Active development is ongoing, with exciting new features planned for future releases. The package aims to empower users by providing easy access to open-source data, enabling them to make informed financial decisions. Currently, the package offers the following features:
- Provides access to detailed information about equity indices.
- Enables downloading and updating daily Total Return Index (
TRI) data for all equity indices. - Fetches closing values for both
Price(excluding dividend reinvestment) andTRIfor all equity indices. - Identifies key turning points in consecutive corrections and recoveries over the historical values of an index.
- Calculates CAGR for both
PriceandTRIindices since the inception. - Compare CAGR (%) between
PriceandTRIindices. - Sorts
PriceandTRIindices by CAGR (%) values. - Sorts
PriceandTRIindices by CAGR (%) within each category. - Compares the year-wise CAGR (%) and growth of a fixed yearly investment across multiple
TRIindices.
- Computes the year-wise SIP return for a fixed monthly contribution to a specified
TRIindex. - Calculates the closing summary of an SIP with a fixed monthly contribution to a specified
TRIindex, starting from a given date. - Compares the year-wise XIRR (%) and growth of a fixed monthly SIP investment across multiple
TRIindices. - Estimates annual SIP performance, including investment amount, closing balance, and cumulative growth over a specified number of years and expected annual return, with options for yearly, quarterly, monthly, or weekly contributions.
- Displays bar graphs of
PriceandTRIindex closing values with descending CAGR (%) since inception, both overall and by index category. - Shows bar graphs of top-performing
PriceandTRIindices by CAGR (%) since launch, with options to view a specified number of top indices, either overall or within each category. - Depicts a bar graph of year-wise investments and returns for a monthly SIP of 1,000 Rupees in a specified
TRIindex since its inception. - Provides a return comparison between a specified index and government bonds for a monthly SIP of 1,000 Rupees over the years.
- Illustrates a line plot comparing the growth of a monthly SIP investment across multiple NSE equity
TRIindices over the years.
Using BharatFinTrack, you can quickly gain insights into the performance of equity indices. For instance, the following bar plot highlights the top five equity indices by TRI CAGR (%) within each category since their respective launches. This snapshot provides a powerful visual overview of long-term performance trends of investment multiples (X) across different index categories over the years. Because performance data updates daily with each trading session, you can replicate and customize this analysis to generate up-to-date insights tailored to your research needs or investment strategies.
In the above graph, the NIFTY MIDCAP150 MOMENTUM 50 emerges as one of the best-performing NSE equity TRI indices in terms of long-term CAGR. The next graph illustrates a comparison of year-wise investments and returns for a monthly SIP of 1,000 Rupees between a government bond and a passive fund tracking the TRI data of NIFTY MIDCAP150 MOMENTUM 50.
Additionally, the following plot compares the growth multiples (X) of a monthly SIP investment across TRI indices, including the popular index NIFTY 50 and other top-performing NSE equity indices over the years.
To install, use pip:
pip install BharatFinTrackA brief example of how to start:
>>> import BharatFinTrack
>>> nse_product = BharatFinTrack.NSEProduct()
>>> nse_product.equity_index_category
['broad', 'sector', 'thematic', 'strategy', 'variant']
# list of all NSE equity indices
>>> nse_product.all_equity_indices
['NIFTY 100',
'NIFTY 200',
'NIFTY 50',
...]For detailed information, see the documentation.
If this project has been helpful and you'd like to contribute to its development, consider sponsoring with a coffee! Support will help maintain, improve, and expand this open-source project, ensuring continued valuable tools for the community.


