qis.FxAccountData¶
- class qis.FxAccountData(spec, **fields)[source]¶
Bases:
objectOwned account histories and event receipts, in explicit monetary units.
Each public field read makes a deep copy to preserve mutation isolation. For reporting loops, read once (for example,
nav = account.nav) and reuse that snapshot; the cost of each read is proportional to the field’s size.- Variables:
spec (qis.portfolio.fx_accounting.FxAccountSpec) – Accounting policy, including initial reference capital.
nav – Marked reference-currency capital, including unsettled receivables.
accounts – Cash, asset, financing and contract values whose sum is NAV.
pnl – Additive reference-currency P&L by economic leg, not percentage returns.
asset_units – Equity units after each date’s trades, held until the next trade.
local_balances – Signed per-asset financing balances in that asset’s currency.
cash_flows – Settlements, asset trades and opening-cash interest in reference units.
contracts – Executed strikes, signed local quantities, fixing and payment receipts.
contract_values – Reference marks by contract; zero before trade and after payment.
diagnostics – Stale-mark flags and accounting reconciliation errors.
provenance – Reset, settlement, rate, financing and notional assumptions.
- Parameters:
spec (FxAccountSpec)
- __init__(spec, **fields)[source]¶
Own the completed results; public reads return independent pandas objects.
- Parameters:
spec (FxAccountSpec)
- Return type:
None
Methods
__init__(spec, **fields)Own the completed results; public reads return independent pandas objects.
Export positive funded NAV for QIS reporting without adding cash a second time.
Attributes
- spec: FxAccountSpec¶
- to_portfolio_data()[source]¶
Export positive funded NAV for QIS reporting without adding cash a second time.
- Returns:
NAV-only PortfolioData. Detailed monetary attribution stays in this ledger.
- Raises:
ValueError – If capital is nonpositive; signed monetary P&L remains inspectable.