Skip to main content
Glama

pyeconomics

Risk-adjusted performance

performance_risk_adjusted
Read-onlyIdempotent

Sharpe, Sortino, Treynor, Jensen's alpha, information ratio and tracking error, M², Calmar and up- and down-capture ratios from return series. Runs Risk-adjusted performance (performance.risk_adjusted, version 1) on the given inputs and returns its canonical result: the validated inputs, the outputs, the warnings and the manifest. Every number carries its unit in the input schema; rates are decimals.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "returns": [
        0.021,
        -0.013,
        0.034,
        0.008,
        -0.022,
        0.015,
        0.027,
        -0.005,
        0.012,
        0.019,
        -0.031,
        0.024
      ],
      "periods_per_year": 12,
      "benchmark_returns": [
        0.018,
        -0.01,
        0.029,
        0.011,
        -0.025,
        0.012,
        0.022,
        -0.002,
        0.01,
        0.016,
        -0.028,
        0.02
      ],
      "risk_free_returns": [
        0.002,
        0.002,
        0.002,
        0.002,
        0.002,
        0.002,
        0.002,
        0.002,
        0.002,
        0.002,
        0.002,
        0.002
      ],
      "minimum_acceptable_return": 0
    },
    "name": "performance_risk_adjusted"
  }
}

Input Schema

NameRequiredDescriptionDefault
returnsYesPortfolio return each period
periods_per_yearYesPeriods in a year, such as 12 or 252
benchmark_returnsYesBenchmark return each period, aligned with the portfolio's
risk_free_returnsNoRisk-free return each period; omit for zero
minimum_acceptable_returnNoMinimum acceptable return per period, for the Sortino ratio

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

Score is being calculated.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.