Skip to main content
Glama

get_individual_stock_metrics

Analyze individual stock performance in a portfolio by calculating return, volatility, Sharpe ratio, and allocation weight metrics to identify top and bottom performers.

Instructions

Get metrics for each individual stock in a portfolio.

Calculates return and volatility metrics for each stock separately, useful for identifying best/worst performers. Args: name: The portfolio name. Returns: Dictionary containing metrics per stock: - mean_return: Average daily return (annualized) - volatility: Standard deviation (annualized) - sharpe_ratio: Individual Sharpe ratio - weight: Current allocation weight Example: ``` result = get_individual_stock_metrics(name="tech_stocks") for symbol, metrics in result['stocks'].items(): print(f"{symbol}: Return={metrics['mean_return']:.2%}") ```

Caching Behavior:

  • Any input parameter can accept a ref_id from a previous tool call

  • Large results return ref_id + preview; use get_cached_result to paginate

  • All responses include ref_id for future reference

Preview Size: server default. Override per-call with get_cached_result(ref_id, max_size=...).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/l4b4r4b4b4/portfolio-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server