Skip to main content
Glama

statistica_correlation_matrix

Build Lag1..LagK correlation products from a time series variable as x(t)*x(t-lag), with optional moving-average smoothing; use shift mode for plain lags.

Instructions

Build lagged series products for a time series: for lags 1..lags it creates variables Lag1..LagK holding x(t)*x(t-lag) (correlation products), optionally smoothed with a moving average, and returns their preview. Use mode "shift" for plain lagged series.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
lagsNoNumber of lag columns to build. Default 12.
modeNoproduct = x(t)*x(t-lag) (default), shift = x(t-lag).
pathYes
sheetNo
attachNoAttach to the already-running STATISTICA instance and edit it live (no new process, the app is not closed).
prefixNoName prefix for the new variables. Default "Lag".
smoothNoMoving-average window applied to each new column.
variableYesSource series.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.3.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It usefully discloses that new variables are created (a mutation) with predictable names, that smoothing is optional, and that only a preview is returned. It does not say whether results are committed to the active spreadsheet, whether existing variables are overwritten, or what permissions/state are required, which are meaningful gaps for a write-style tool.

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

Conciseness4/5

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

Front-loaded with the purpose and mechanics in one dense sentence, followed by a short mode hint. No filler, and every clause contributes information. Slightly dense but appropriately sized for an 8-parameter tool.

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

Completeness3/5

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

Given 8 parameters, no annotations, and no output schema, the description adequately explains what is produced (and that only a preview is returned, so no output schema needed) but leaves side-effect and state-management questions unanswered. It is minimally sufficient rather than complete for a mutating spreadsheet operation.

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 description coverage is 75%, so most parameters carry their own documentation and the baseline is 3. The description reinforces the meaning of lags (1..lags -> Lag1..LagK), the product formula, smoothing, and the shift mode, but adds nothing for path, sheet, attach, or prefix beyond what the schema already states.

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

Purpose4/5

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

States a concrete verb and resource with mechanical detail: it 'builds lagged series products', creates variables 'Lag1..LagK holding x(t)*x(t-lag)', optionally smooths, and returns a preview. This is specific enough for an agent to know exactly what the tool constructs. It does not, however, name or differentiate against plausible siblings such as add_lag_column or statistica_correlation, and the name 'correlation_matrix' does not match the described behavior, which slightly undercuts disambiguation.

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

Usage Guidelines3/5

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

'Use mode "shift" for plain lagged series' gives a real selection rule for one parameter mode, and the default product mode is implied. But there is no guidance on when to use this tool versus add_lag_column or statistica_correlation, nor any prerequisites such as whether the spreadsheet must be open. Usage is implied rather than framed as when/when-not.

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