Technical package

Submodules

Technical.NSE module

class Technical.NSE.NSE[source]

Bases: NSEBase

A class to interact with the NSE (National Stock Exchange) API.

Attributes:

mc : an instance of the MoneyControl class

Methods:
get_important_reports(report_name)

Retrieves the data for a specific report from the NSE API.

Args:

report_name: The name of the report.

Returns:

The response of the request made to the NSE API.

Get_equities_data_from_index(index=’SECURITIES IN F&O’)

Retrieves a pandas dataframe containing information about equities from a specific index.

Args:

index: The index for which to retrieve the data. Defaults to ‘SECURITIES IN F&O’.

Returns:

A dataframe with columns for symbol, series, security name, and last price.

Get_all_indices()

Retrieves a dataframe containing information about all indices.

Returns:

A dataframe with information about all indices.

Get_trade_info(ticker)

Retrieves trade information for a given ticker or list of tickers.

Args:

ticker: The ticker or list of tickers for which to retrieve trade information.

Returns:

A dataframe with trade information.

Get_corporate_disclosures(ticker)

Retrieves corporate disclosures

get_all_etf()[source]

Get trade information of all ETFs (Exchange Traded Funds)

Parameters:

self – Represents the instance of the class

Returns:

DataFrame containing data of all ETFs

get_all_indices()[source]

This will give a complete dataframe of all indices and its minimalistic data like OHLC

Parameters:

self – Represents the instance of the class

Returns:

A DataFrame of all indices traded on NSE

get_all_today_block_deals()[source]

Get trade information for all block deals happened today;

Parameters:

self – Represents the instance of the class

Returns:

DataFrame containing block deals data.

get_corporate_disclosures(ticker: list) dict[source]

Get corporate disclosure data

Parameters:
  • self – Represents the instance of the class

  • ticker – this can a string represents single ticker ot list tickers.

Returns:

DataFrame contains the corporate disclosures data

get_equities_data_from_index(index='SECURITIES IN F&O')[source]
The get_equities_data_from_index function returns a dataframe containing the following information:
  • Symbol

  • Series (e.g. EQ, BE)

  • Security Name (e.g. ACC LIMITED)

  • Last Price (in Rs.) # This is the last traded price of the equity on NSE for that day’s trading session

    # at 15:30 IST or 16:00 IST depending on whether it is a normal trading day or not respectively

Parameters:
  • self – Represent the instance of the class

  • index – Specify the index for which we want to get the data

Returns:

A dataframe with the following columns:

get_important_reports() dict[source]

The get_important_reports function takes in a report_name and returns the data for that report. The function uses the try_n_times_get_response function to get a response from NSE’s API. If there is no error, it will return the data for that particular report.

Parameters:

self – Represents the instance of the class

Returns:

A dict of objects which will give links to various reports

get_india_vix(interval: str) DataFrame[source]

This will fetch the OHLCV datapoints of the INDIA Volatility Index.

Parameters:

interval – Time interval for the data (‘1d’ for daily qnd ‘1’ for 1min)

Returns:

DataFrame containing the India VIX data for last 2months or ~1780 OHLCV datapoints

get_sgb_data()[source]

Get trade information of Sovereign Gold Bonds data

Parameters:

self – Represents the instance of the class

Returns:

DataFrame containing the trade information for SGB.

get_sme_stocks()[source]

Get SME (Small Medium Enterprises) data

Parameters:

self – Represents the instance of the class

Returns:

DataFrame containing SME Stocks data.

get_trade_info(ticker: list) DataFrame[source]

Get trade information for one or more ticker(s).

Parameters:
  • self – Represents the instance of the class

  • ticker – this can a string represents single ticker ot list tickers.

Returns:

DataFrame containing the trade information for the given ticker(s).

Module contents