calculate_financial_ratios
Compute valuation, profitability, liquidity, and efficiency ratios for NSE/BSE-listed Indian stocks, filling in metrics Yahoo leaves null using financial statement data.
Instructions
Calculate valuation, profitability, liquidity, and efficiency ratios
for the latest fiscal period of an NSE/BSE-listed Indian equity. Ratios
Yahoo leaves null for Indian tickers (roce, roe, roa, current_ratio,
interest_coverage, asset_turnover) are computed by hand from the income
statement and balance sheet instead of read off .info.
:param symbol: ticker symbol, e.g. "RELIANCE", "TCS.NS", or "TCS.BO"
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| symbol | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pb | No | Price to book | |
| pe | No | Trailing P/E | |
| roa | No | Net Income / Total Assets | |
| roe | No | Net Income / Stockholders Equity | |
| roce | No | EBIT / Invested Capital | |
| symbol | Yes | ||
| ev_sales | No | ||
| ev_ebitda | No | ||
| fcf_yield | No | Free Cash Flow / Market Cap | |
| forward_pe | No | ||
| net_margin | No | ||
| fiscal_date | No | ||
| gross_margin | No | ||
| current_ratio | No | Current Assets / Current Liabilities | |
| asset_turnover | No | Revenue / Total Assets | |
| dividend_yield | No | ||
| earnings_yield | No | Net Income / Market Cap. Approximately but not exactly 1/PE -- PE uses trailing-twelve-month EPS, this uses latest full-year net income. | |
| operating_margin | No | ||
| interest_coverage | No | EBIT / Interest Expense | |
| debt_to_equity_pct | No | Total Debt as a percent of equity (e.g. 10.21 means 10.21%, NOT a 10x ratio), straight from Yahoo's `.info` | |
| currency_mismatch_warning | No | Set when Yahoo's market-data currency and financial-statement currency disagree for this ticker (live-confirmed on some Indian large caps) -- treat pe/pb/ev_ebitda/ev_sales/fcf_yield/earnings_yield as unreliable when set. |