tax_run_spv: Run a generic SPV-level tax engine

View source: R/tax.R

tax_run_spvR Documentation

Run a generic SPV-level tax engine

Description

Run a generic SPV-level tax engine

Usage

tax_run_spv(tax_basis, tax_spec, acquisition_price = NULL)

Arguments

tax_basis

Data frame with at least year, noi, capex, and interest. Optional columns include sale_proceeds, taxable_sale_proceeds, pre_tax_equity_cf, and acquisition_price.

tax_spec

Object returned by tax_spec_spv().

acquisition_price

Optional numeric scalar. Acquisition tax basis used for the initial asset split. If NULL, the function tries to infer it from tax_basis.

Value

A list with:

  • tax_table: yearly tax table,

  • summary: one-row tibble with headline tax aggregates,

  • tax_spec: the specification used for the run,

  • acquisition_price: acquisition basis actually used.

Examples

basis <- tibble::tibble(
  year = 0:4,
  noi = c(0, 140, 150, 160, 170),
  capex = c(0, 0, 20, 0, 0),
  interest = c(0, 30, 25, 20, 0),
  sale_proceeds = c(0, 0, 0, 0, 900),
  pre_tax_equity_cf = c(-1000, 110, 105, 120, 950)
)

spec <- tax_spec_spv(
  corp_tax_rate = 0.25,
  depreciation_spec = depreciation_spec(
    acquisition_split = tibble::tribble(
      ~bucket,    ~share, ~life_years, ~method,          ~depreciable,
      "land",      0.20,        NA,    "none",           FALSE,
      "building",  0.80,         4,    "straight_line",  TRUE
    ),
    capex_bucket = "building",
    start_rule = "full_year"
  )
)

out <- tax_run_spv(basis, spec, acquisition_price = 1000)
out$summary

cre.dcf documentation built on April 10, 2026, 5:08 p.m.