Skip to content
Agentmart
Submit a tool

画图

使用matplotlib生成论文级质量图表,支持柱状图、折线图、热力图、散点图、饼图、箱线图等

Skill by hongdotien10-hash

IndexedMIT
Write a review

Chalk Labs

Need help deploying 画图?

Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.

Book a call

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/hongdotien10-hash-f7bd0c

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

使用matplotlib生成论文级质量图表,支持柱状图、折线图、热力图、散点图、饼图、箱线图等

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/mrite-figure

What's inside

Skill name
画图
Description
使用matplotlib生成论文级质量图表,支持柱状图、折线图、热力图、散点图、饼图、箱线图等
License
MIT
Instructions
259 lines in SKILL.md · view on GitHub

Agent Skills spec issues

  • name: only lowercase letters, digits and single hyphens allowed
  • name: "画图" does not match folder "mrite-figure"

Files (1)

  • SKILL.md

SKILL.md (first lines)

# 画图技能

## 目的

使用 matplotlib 生成论文级质量图表,每张图150dpi,中文坐标轴和图例。

## 环境配置(必须)

```python
import matplotlib
matplotlib.use('Agg')
import matplotlib.pyplot as plt
import numpy as np

# 中文字体(跨平台兼容)
plt.rcParams['font.sans-serif'] = ['STHeiti', 'SimHei', 'Heiti TC',
    'Arial Unicode MS', 'Hiragino Sans GB', 'PingFang SC',
    'Microsoft YaHei', 'Songti SC', 'DejaVu Sans']
plt.rcParams['axes.unicode_minus'] = False
plt.rcParams['figure.dpi'] = 150
plt.rcParams['savefig.dpi'] = 150
plt.rcParams['savefig.bbox'] = 'tight'
```

## ⛔ 唯一绘图库

**只允许 matplotlib**,严禁 seaborn、plotly、plotnine、altair、bokeh、holoviews。

| 禁止 | 替代方案 |
|------|----------|
| `import seaborn as sns` | matplotlib 原生 API |
| `sns.set_style()` | `plt.rcParams` + `ax.grid()` |
| `sns.color_palette()` | `plt.cm.viridis(np.linspace(0.1, 0.9, n))` |
| `sns.heatmap()` | `ax.imshow()` + `plt.colorbar()` |
| `sns.despine()` | `ax.spines['top'].set_visible(False)` |

## 通用美化函数

```python
def despine(ax):
    """去除顶部和右侧边框"""
    ax.spines['top'].set_visible(False)
    ax.spines['right'].set_visible(False)

def apply_style(ax):
    """通用样式"""
    ax.grid(alpha=0.3, linestyle='--')
    despine(ax)
    # 图上不画 set_title(),标题由论文 \caption{} 承担
```

## 配色方案

```python
# 方案1: Viridis(默认推荐)
colors = plt.cm.viridis(np.linspace(0.1, 0.9, n))

# 方案2: RdBu_r(对比型)
colors = plt.cm.RdBu_r(np.linspace(0.15, 0.85, n))

# 方案3: tab10(离散类别)
colors = [f'C{i}' for i in range(n)]

# 方案4: Set3(柔和色)
colors = plt.cm.Set3(np.linspace(0, 1, n))
```

## 各类型图表模板

### 柱状图

```python
fig, ax = plt.subplots(figsize=(10, 6))
x = np.arange(len(categories))
bars = ax.bar(x, values, width=0.6, edgecolor='white',
              linewidth=0.5, color=plt.cm.viridis(np.linspace(0.1, 0.9, len(categories))))
ax.set_xticks(x)
ax.set_xticklabels(categories, rotation=30, ha='right')
ax.set_ylabel('数值')
# 柱顶标注数值
for bar, val in zip(bars, values):
    ax.text(bar.get_x() + bar.get_width()/2, bar.get_height() + 0.5,
            f'{val:.2f}', ha='center', va='bottom', fontsize=9)
apply_style(ax)
```

### 折线图

```python
fig, ax = plt.subplots(figsize=(10, 6))
ax.plot(x, y, linewidth=2, marker='o', markersize=5,
        color='C0', markerfacecolor='white', markeredgewidth=1.5)
ax.set_xlabel('X轴标签')
ax.set_ylabel('Y轴标签')
apply_style(ax)
```

### 多系列折线图

```python
fig, ax = plt.subplots(figsize=(10, 6))
for i, (label, data) in enumerate(series.items()):
    ax.plot(x, data, linewidth=2, marker='o', markersize=4, label=label)
ax.set_xlabel('X轴标签')
ax.set_ylabel('Y轴标签')
ax.legend(loc='best', frameon=True, fancybox=True)
apply_style(ax)
```

### 热力图

```python
fig, ax = plt.subplots(figsize=(10, 8))
im = ax.imshow(data_matrix, cmap='RdBu_r', aspect='auto',
                vmin=np.min(data_matrix), vmax=np.max(data_matrix))
cbar = plt.colorbar(im, ax=ax, shrink=0.8)
cbar.set_label('数值')
ax.set_xticks(range(len(col_labels)))
ax.set_xticklabels(col_labels, rotation=45, ha='right')

From hongdotien10-hash/mathmodel-toolkit, MIT.

More from hongdotien10-hash/mathmodel-toolkit

Signals

Stars
0
Forks
0
Open issues
0
Last commit (this folder)
Jul 22, 2026 (3 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from hongdotien10-hash

Done for you

Rather not set it up yourself?

Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.

See how we build AI agents →Read the case studies

Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.

launches shipped
50+
launches shipped
media placements
500+
media placements
founders on every account
2
founders on every account

Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block

Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.

Get 画图 running in your business

Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.

Goes to the Chalk Labs founders, not the newsletter. Privacy

Need help deploying 画图?

CallGet help
Cite this page

画图 skill. Agent Mart. https://agentmart.dev/skills/hongdotien10-hash-f7bd0c (last updated 2026-10-24)