---
title: "Sharpe Ratio Contributions"
method: POST
path: "/portfolios/analysis/contributions/sharpe-ratio"
tags: ["Portfolio Analysis / Contributions"]
---

# Sharpe Ratio Contributions

`POST /portfolios/analysis/contributions/sharpe-ratio`

Perform a Sharpe Ratio contribution analysis of a portfolio.

References
* [Sestovic, Dragan, Marginal Sharpe Ratio](https://papers.ssrn.com/sol3/papers.cfm?abstract_id=4916095)

## Request body

- object
  - `assets` integer, required — The number of assets
  - `assetsMeanReturns` number[], required — assetsMeanReturns[i] is the arithmetic (expected) return of asset i
  - `assetsCovarianceMatrix` array[], required — assetsCovarianceMatrix[i][j] is the covariance between the asset i and the asset j
    - number[]
  - `riskFreeReturn` number — The constant risk-free arithmetic return over the considered time period, in percentage
  - `assetsGroups` array[]
    - integer[] — assetsGroups[k] is the indexes of the assets belonging to the assets group k
  - `portfolios` object[], required
    - `assetsWeights` number[], required — assetsWeights[i] is the weight of the asset i in the portfolio, in percentage

## Response `200`

OK

- object
  - `portfolios` object[], required
    - `assetsMarginalSharpeRatioContributions` number[], required — assetsMarginalSharpeRatioContributions[i] is the marginal Sharpe Ratio contribution of the asset i to the Sharpe Ratio of the portfolio
    - `assetsRelativeSharpeRatioContributions` number[] — assetsRelativeSharpeRatioContributions[i] is the relative Sharpe Ratio contribution of the asset i to the Sharpe Ratio of the portfolio, in percentage; assetsRelativeSharpeRatioContributions is not provided when the Sharpe Ratio of the portfolio is equal to 0
    - `assetsTotalSharpeRatioContributions` number[], required — assetsTotalSharpeRatioContributions[i] is the total Sharpe Ratio contribution of the asset i to the Sharpe Ratio of the portfolio
    - `assetsGroupsRelativeSharpeRatioContributions` number[] — assetsGroupsRelativeSharpeRatioContributions[k] is the relative Sharpe Ratio contribution of the group of assets k to the Sharpe Ratio of the portfolio, in percentage; assetsGroupsRelativeSharpeRatioContributions is not provided when the Sharpe Ratio of the portfolio is equal to 0
    - `assetsGroupsTotalSharpeRatioContributions` number[] — assetsGroupsTotalSharpeRatioContributions[k] is the total Sharpe Ratio contribution of the group of assets k to the Sharpe Ratio of the portfolio

---

[API](https://skmtc.net/portfoliooptimizer/apis/portfolio-optimizer.md) · [All operations](https://skmtc.net/portfoliooptimizer/apis/portfolio-optimizer/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/portfoliooptimizer/portfolio-optimizer/revisions/d016f340e91c/schema)
