Risk Parity Weights
workflow.run_risk_parityRisk-parity (equal or custom risk contribution) portfolio weights for N assets: given a covariance matrix (or N return series to compute one from), finds long-only weights where each asset contributes its target share of total portfolio risk. Use when user asks "what weights give each asset equal risk contribution?" or "how do I risk-parity-weight this portfolio?". A portfolio-construction calculation, not a buy/sell recommendation. Returns: weights, risk_contributions (should match risk_budgets exactly at convergence), portfolio_volatility.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| returns | No | One return series per asset (2+ assets, all series the same length). Provide this OR covariance, not both. | |
| covariance | No | Direct NxN covariance matrix, if not supplying returns[][] directly. | |
| risk_budgets | No | Target risk share per asset, one per asset (need not sum to 1, normalized internally). Default: equal (1/N each). |