The autodcf.models.DCF class provides a sophisticated interface that allows users to easily make complex assumptions about sales growth, and relation of line items (e.g. R&D, Capex, COGS) to sales.

class autodcf.models.DCF(company, sales_growth, discount_rate, terminal_growth_rate, window, cogs_to_sales, sga_to_sales, rd_to_sales, da_to_sales, interest_to_sales, tax_rate, capex_to_sales, change_in_nwc_to_change_in_sales)

Class for flexible DCF.

Note that all _to_sales args take either an iterable or float. If given a float, the DCF will use this constant across all time periods (ex: if given 0.45 for COGS, COGS will be 45% of sales for all forecasted periods). If given iterable, the first value will be the value used for the first year in the forecast and the last value will be the value used in the terminal year.

  • company (autodcf.company.Company) – Company to do DCF analysis for.

  • sales_growth (Union[Iterable, float]) – Iterable of sales growth numbers to iterate over or constant growth rate. Values are in order, so first value in iterable applies to next sales period and last value applies to last sales period in DCF. Note, if you want to have 5% sales growth, use 0.05.

  • discount_rate (float) – Rate at which cash flow should be discounted.

  • terminal_growth_rate (float) – Rate at which sales are estimated to grow after returning to normal profit levels.

  • window (int) – Number of years until company returns to normal profit margins (terminal year).

  • cogs_to_sales (Union[Iterable, float]) – COGS as % of sales.

  • sga_to_sales (Union[Iterable, float]) – SGA as % of sales.

  • rd_to_sales (Union[Iterable, float]) – R&D as % of sales.

  • da_to_sales (Union[Iterable, float]) – Depreciation & amortization as % of sales. Assumes amortization is tax deductible.

  • interest_to_sales (Union[Iterable, float]) – Interest as % of sales.

  • tax_rate (float) – Tax rate.

  • capex_to_sales (Union[Iterable, float]) – Capex as % of sales.

  • change_in_nwc_to_change_in_sales (float) – Ratio of how much net working capital must change to increase sales by 1 unit.

property capex_to_sales

Capital expenditures as a percentage of sales.

property change_in_nwc_to_change_in_sales

How much net working capital is expected to need to increase for each dollar increase in sales.

property cogs_to_sales

Cost of goods sold as a percentage of sales.

property company

Company object to do DCF for.

property da_to_sales

Depreciation and amortization as a percentage of sales.

property discount_rate

Discount rate to discount cash flow at.

property discounted_terminal_cash_flow

Sum of discounted cash flows after window.

property discounted_window_cash_flow

Add up discounted cash flows from window.

property enterprise_value

Enterprise value given by discounted cash flow analysis.

property equity_value

Returns total equity value of firm.

property equity_value_per_share

Equity value divided by total number of shares outstanding.


Get pandas dataframe with all info needed to complete forecast.


Pandas data frame with forecasted future income statements and discounted

free cash flows.

Return type

forecast (pd.DataFrame)

property interest_to_sales

Interest expense as a percentage of sales.

property rd_to_sales

Research and development costs as a percentage of sales.

property sales_growth

Numpy array of sales growth for each year until end of window.

property sga_to_sales

Selling, general, and administrative costs as a percentage of sales.

property tax_rate

Effective tax rate for company.

property terminal_growth_rate

Rate at which sales are expected to grow perpetually.

property window

Periods of normal sales growth until terminal growth rate takes over.