본문으로 건너뛰기
cccskills
무료GitHub에 공개

chart-visualization

Generate charts: select type, extract data, render image.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(1)

  • SKILL.md4.0 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Chart Visualization

Overview

Transform data into visual charts. Intelligently select the most suitable chart type, extract parameters, and generate a chart image.

Poirot note: The original deer-flow skill uses a bundled scripts/generate.js (Node.js + charting library). Poirot doesn't bundle that script. Use bash with Python (matplotlib/plotly) as the rendering engine instead. Install: pip install matplotlib plotly.

Chart Selection Guide

Data PatternRecommended ChartWhen
Time SeriesLine / AreaTrends over time
ComparisonsBar / ColumnCategorical comparison
DistributionHistogram / BoxplotFrequency distribution
Part-to-WholePie / TreemapProportions
RelationshipsScatterCorrelation
FlowSankeyFlow between stages
Multi-dimensionalRadarCompare across dimensions
ProcessFunnelStage conversion
HierarchyOrg chart / Mind mapTree structure
GeographicMapSpatial data

Workflow

1. Select Chart Type

Analyze the user's data features:

  • Time dimension? → Line/Area
  • Categories? → Bar/Column
  • Proportions? → Pie/Treemap
  • Correlation? → Scatter
  • Flow? → Sankey
  • Multiple dimensions? → Radar

2. Prepare Data

Extract data from user input, format as Python data structure:

data = {
    "labels": ["Jan", "Feb", "Mar", "Apr", "May"],
    "values": [120, 150, 180, 200, 220],
    "title": "Monthly Revenue",
    "xlabel": "Month",
    "ylabel": "Revenue ($K)"
}

3. Generate Chart

python3 -c "
import matplotlib
matplotlib.use('Agg')  # non-interactive backend
import matplotlib.pyplot as plt

labels = ['Jan', 'Feb', 'Mar', 'Apr', 'May']
values = [120, 150, 180, 200, 220]

fig, ax = plt.subplots(figsize=(10, 6))
ax.plot(labels, values, marker='o', linewidth=2, markersize=8)
ax.set_title('Monthly Revenue', fontsize=16, fontweight='bold')
ax.set_xlabel('Month', fontsize=12)
ax.set_ylabel('Revenue ($K)', fontsize=12)
ax.grid(True, alpha=0.3)
plt.tight_layout()
plt.savefig('.poirot/outputs/chart.png', dpi=150, bbox_inches='tight')
print('Saved to .poirot/outputs/chart.png')
"

Common Chart Types via matplotlib

# Bar chart
python3 -c "
import matplotlib; matplotlib.use('Agg')
import matplotlib.pyplot as plt
cats = ['A', 'B', 'C', 'D']
vals = [23, 45, 12, 67]
plt.bar(cats, vals, color=['#4CAF50', '#2196F3', '#FF9800', '#F44336'])
plt.title('Category Comparison')
plt.savefig('.poirot/outputs/bar.png', dpi=150)
"

# Scatter plot
python3 -c "
import matplotlib; matplotlib.use('Agg')
import matplotlib.pyplot as plt
import numpy as np
x = np.random.randn(100)
y = x * 0.8 + np.random.randn(100) * 0.5
plt.scatter(x, y, alpha=0.6, c='steelblue')
plt.title('Correlation Scatter')
plt.savefig('.poirot/outputs/scatter.png', dpi=150)
"

# Pie chart
python3 -c "
import matplotlib; matplotlib.use('Agg')
import matplotlib.pyplot as plt
labels = ['Product A', 'Product B', 'Product C']
sizes = [45, 35, 20]
plt.pie(sizes, labels=labels, autopct='%1.1f%%', startangle=90)
plt.title('Market Share')
plt.savefig('.poirot/outputs/pie.png', dpi=150)
"

Pitfalls

  • matplotlib backend: always use matplotlib.use('Agg') for non-interactive (headless) rendering. Without it, matplotlib may try to open a GUI window.
  • Chinese characters: matplotlib may not render CJK by default. Set font: plt.rcParams['font.sans-serif'] = ['SimHei', 'Arial Unicode MS']
  • DPI: use dpi=150 for crisp images. dpi=300 for print quality.
  • File size: PNG is standard. Use SVG for vector (plt.savefig('chart.svg')).
  • Color palettes: use colorblind-friendly palettes. Avoid red/green only.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Structured peer-review of academic papers.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

HezaoHezao/poirot2512026년 7월 29일 업데이트

Dark-themed SVG architecture/cloud/infra diagrams as HTML.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

HezaoHezao/poirot2512026년 7월 29일 업데이트

arxiv

무료

Search arXiv papers by keyword, author, category, or ID.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

HezaoHezao/poirot2512026년 7월 29일 업데이트

Monitor blogs and RSS/Atom feeds via blogwatcher-cli.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

HezaoHezao/poirot2512026년 7월 29일 업데이트

bootstrap

무료

Onboarding conversation to generate a user profile.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

HezaoHezao/poirot2512026년 7월 29일 업데이트

Generate docs: README, API reference, architecture, guides.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

HezaoHezao/poirot2512026년 7월 29일 업데이트

HezaoHezao의 스킬 모두 보기

이 스킬의 문제 신고