Skip to main content
Glama

plot_box

Generate box plots to compare data distributions by visualizing medians, quartiles, and outliers for statistical analysis.

Instructions

Create a box plot for comparing data distributions.

This tool generates box plots (box-and-whisker plots) showing median, quartiles, and outliers for one or more datasets.

Args: data: For direct input, list of lists (each sublist is a dataset). For file input, column name(s) separated by comma or single column. data_input: Optional. {"file_path": "path/to/file.csv"} or {"data": {...}} labels: Optional labels for each dataset style: Optional. {"title": "...", "xlabel": "...", "ylabel": "...", "grid": True} output: Optional. {"format": "png/pdf/svg", "width": 15, "height": 10, "dpi": 300}

Returns: PIL Image object or bytes containing the plot

Examples: Multiple datasets comparison: >>> plot_box( ... data=[[1, 2, 3, 4, 5], [2, 3, 4, 5, 6], [3, 4, 5, 6, 7]], ... labels=["Group A", "Group B", "Group C"] ... )

From CSV file:
>>> plot_box(
...     data="scores",
...     data_input={"file_path": "test_scores.csv"},
...     style={"title": "Test Score Distribution"}
... )

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataYes
data_inputNo
labelsNo
styleNo
outputNo
Behavior3/5

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

With no annotations provided, the description carries full burden. It explains the tool generates visualizations and returns PIL Image/bytes, but doesn't mention performance characteristics, error conditions, or whether it modifies input data. The examples help but don't fully cover 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.

Conciseness4/5

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

Well-structured with clear sections: purpose statement, parameter explanations, return value, and examples. The information is front-loaded with the core purpose first. Some redundancy exists (data parameter explained in both Args and examples), but overall efficient.

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?

For a 5-parameter visualization tool with no annotations and no output schema, the description provides good coverage: clear purpose, parameter semantics, return format, and usage examples. It could benefit from more behavioral context (error handling, performance) but is largely complete.

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

Parameters4/5

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

With 0% schema description coverage, the description compensates well by explaining all 5 parameters with clear semantics: data formats (list of lists vs. column names), optional data_input for files, labels for datasets, style for plot customization, and output for format/dimensions. The examples further clarify 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 box plot for comparing data distributions' with specific details about what the plot shows (median, quartiles, outliers). It distinguishes from siblings by specifying it's for box plots, unlike plot_bar, plot_line, etc.

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?

The description provides implied usage through examples showing when to use direct data input vs. file input, but lacks explicit guidance on when to choose this tool over sibling tools like plot_violin or plot_histogram for similar distribution visualization tasks.

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