Skip to main content
Glama

correlation_analysis

Compute Pearson correlation of daily log-returns between two currency pairs to quantify co-movement over a selectable period, with values from -1 to +1.

Instructions

Compute the Pearson correlation of daily log-returns between two currency pairs over N days. Useful for understanding co-movement: NZD/USD vs AUD/USD typically correlate highly (~0.85). Range: -1 (inverse) to +1 (perfect).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
daysNoLookback window in days (10–90, default 30)
pair1_toYesQuote currency of first pair (e.g. USD)
pair2_toYesQuote currency of second pair (e.g. USD)
pair1_fromYesBase currency of first pair (e.g. NZD)
pair2_fromYesBase currency of second pair (e.g. AUD)
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries full burden. It discloses that it uses daily log-returns and Pearson correlation with range -1 to 1. However, it does not mention assumptions (e.g., linearity, normality), data requirements, or behavior for edge cases (e.g., missing days, pair not found). It adds value over schema by explaining log-returns and interpretation but lacks depth.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Description is very concise: two sentences plus a brief range note. The core action is front-loaded in the first sentence. Every word contributes meaning without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, so description should clarify what the tool returns. It does explain the output range (correlation coefficient -1 to +1). However, it does not explicitly state the return format (single float? object with additional stats?) or mention any assumptions or limitations (e.g., linearity, data sufficiency). Overall, it covers the essential context for a correlation tool but could be slightly more complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3. Description adds context with example currencies (NZD, AUD, USD) and explains that pair1_from/pair1_to are base/quote currencies, but this does not significantly enhance understanding beyond the schema's parameter descriptions. No additional constraints or semantics for 'days' parameter beyond schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states it computes Pearson correlation of daily log-returns between two currency pairs over N days. Verb 'compute' and resource 'correlation' are specific. Example with NZD/USD vs AUD/USD and explanation of output range (-1 to +1) further clarify purpose, distinguishing it from sibling tools like moving_average or volatility_analysis.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Description provides a clear usage scenario: 'Useful for understanding co-movement' with a concrete example. However, it does not explicitly state when not to use it or suggest alternative tools for different needs, which would improve guidance for an AI agent.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/CedricConday/xe-mcp'

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