get_statistics
Analyze signal data from PicoScope oscilloscopes to calculate statistical metrics including minimum, maximum, mean, and standard deviation values for signal analysis.
Instructions
Get statistical analysis of signal.
Args: channel: Channel to analyze. num_samples: Number of samples to analyze.
Returns: Dictionary containing min, max, mean, std dev, etc.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| channel | Yes | ||
| num_samples | No |
Implementation Reference
- The handler function implementing the 'get_statistics' tool logic, registered via @mcp.tool() decorator. It computes statistics on a specified channel using a given number of samples (currently stubbed with TODO).@mcp.tool() def get_statistics( channel: Literal["A", "B", "C", "D"], num_samples: int = 1000 ) -> dict[str, Any]: """Get statistical analysis of signal. Args: channel: Channel to analyze. num_samples: Number of samples to analyze. Returns: Dictionary containing min, max, mean, std dev, etc. """ # TODO: Implement statistics calculation return {"status": "not_implemented", "channel": channel, "num_samples": num_samples}
- src/picoscope_mcp/server.py:18-18 (registration)The call to register_analysis_tools which defines and registers the get_statistics tool (among others) with the MCP server instance.register_analysis_tools(mcp)