Skip to main content
Glama

plot_pcolormesh

Create pseudocolor plots for large datasets on irregular grids to visualize 2D data distributions in scientific research.

Instructions

Create a pseudocolor plot with a non-regular rectangular grid.

This tool generates a fast pseudocolor plot using pcolormesh, ideal for large datasets and irregular grids.

Args: x: X coordinates. Column name or list of values. y: Y coordinates. Column name or list of values. z: Z values (2D array). Column name or 2D list. data_input: Optional. {"file_path": "path/to/file.csv"} or {"data": {...}} shading: Shading method ("auto", "flat", "nearest", "gouraud") style: Optional. {"title": "...", "xlabel": "...", "ylabel": "...", "colormap": "viridis"} output: Optional. {"format": "png/pdf/svg", "width": 15, "height": 10, "dpi": 300}

Returns: PIL Image object or bytes containing the plot

Examples: Basic pcolormesh: >>> x = [1, 2, 3, 4] >>> y = [1, 2, 3, 4] >>> z = [[1, 2, 3, 4], [2, 4, 6, 8], [3, 6, 9, 12], [4, 8, 12, 16]] >>> plot_pcolormesh(x=x, y=y, z=z, shading="gouraud")

From file with custom colormap:
>>> plot_pcolormesh(
...     x="x_coord",
...     y="y_coord",
...     z="intensity",
...     data_input={"file_path": "field_data.csv"},
...     style={"colormap": "plasma", "title": "Field Intensity"}
... )

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xYes
yYes
zYes
data_inputNo
shadingNoauto
styleNo
outputNo
Behavior4/5

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

With no annotations provided, the description carries the full burden. It discloses key behavioral traits: it's a creation tool (implies mutation/write operation), returns a PIL Image or bytes, and mentions performance ('fast') and ideal use cases. However, it lacks details on permissions, error handling, or side effects. The description adds substantial value beyond the schema but doesn't cover all behavioral aspects.

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?

The description is well-structured and appropriately sized. It starts with a clear purpose, followed by usage context, detailed parameter explanations with examples, and return value. Every sentence adds value: no redundancy, and the examples illustrate practical usage efficiently. It's front-loaded with key information.

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

Completeness5/5

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

Given the complexity (7 parameters, no annotations, no output schema), the description is highly complete. It covers purpose, usage, all parameter semantics with examples, and return values. The examples demonstrate both basic and advanced usage, compensating for the lack of structured fields. This provides sufficient context for an AI agent to invoke the tool correctly.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate fully. It provides detailed semantics for all 7 parameters: x, y, z (coordinates and values with format options), data_input (file or data object), shading (method with enum values), style (plot customization), and output (format and dimensions). The description adds comprehensive meaning beyond the bare schema, including examples and optional usage.

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?

The description clearly states the tool's purpose: 'Create a pseudocolor plot with a non-regular rectangular grid' and 'generates a fast pseudocolor plot using pcolormesh, ideal for large datasets and irregular grids.' It specifies the verb ('create'), resource ('pseudocolor plot'), and distinguishes from siblings by emphasizing irregular grids and large datasets, which differentiates it from regular heatmap or contour plots.

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?

The description provides clear context for when to use this tool: 'ideal for large datasets and irregular grids.' This implicitly suggests alternatives (e.g., use other plot types for regular grids or smaller datasets), but it does not explicitly name sibling tools or state when-not-to-use scenarios. The guidance is helpful but not exhaustive.

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/nishide-dev/ml-research-mcp'

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