Master 1Password: vaults, Watchtower, passkeys, SSH agent, CLI, and family/team administration. Use when getting full value from 1Password personally or administering it for others.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Build custom data visualizations with D3: selections, scales, axes, transitions, and reusable chart patterns. Use when off-the-shelf charts aren't enough.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
설치 방법 보기설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.
A practical guide to D3.js: the low-level visualization toolkit — selections and the data join, scales, axes, shapes, transitions, and building reusable, responsive custom charts.
D3 is not a chart library; it's a visualization toolkit. You bind data to DOM/SVG elements and describe how data maps to visuals. That means total control (any chart ever invented, plus new ones) at the cost of writing more code. Use D3 when the design is custom; use a chart library when it's standard.
The core pattern: select elements → join data → enter/update/exit → map data through scales → transition changes.
d3.select('svg').selectAll('circle') — D3's jQuery-like DOM API with data binding..data(data, keyFn).join(enter => ..., update => ..., exit => ...) — the heart of D3. Key functions keep element identity stable across updates (no key = index-based, which scrambles on reorder).scaleLinear, scaleTime, scaleBand, scaleOrdinal, scaleLog — map data domain → visual range. scaleBand for bars (with padding), scaleTime handles dates/irregular intervals.axisBottom(scale) renders ticks; customize with tickFormat, ticks(n). Style via CSS, not attributes, for maintainability.line(), area(), arc() (pies/donuts/gauges); layouts: pie(), stack(), hierarchy() + treemap()/pack(), forceSimulation() for networks..transition().duration(750).attr(...) — interpolates attributes; interrupt-safe. Animate data changes, not just entrances.d3.zoom() (pan/zoom with rescaled axes), d3.brush() (range selection) — the building blocks of interactive exploration.d3-scale, d3-selection) to keep bundles small.1. Scaffold (margin convention).
const margin = { top: 20, right: 20, bottom: 40, left: 50 };
const width = 640 - margin.left - margin.right;
const height = 400 - margin.top - margin.bottom;
const svg = d3.select('#chart').append('svg')
.attr('viewBox', `0 0 ${width + margin.left + margin.right} ${height + margin.top + margin.bottom}`)
.attr('role', 'img').attr('aria-label', 'Monthly revenue bar chart');
const g = svg.append('g').attr('transform', `translate(${margin.left},${margin.top})`);
viewBox (not fixed width/height) = responsive for free.
2. Scales + axes.
const x = d3.scaleBand().domain(data.map(d => d.month)).range([0, width]).padding(0.2);
const y = d3.scaleLinear().domain([0, d3.max(data, d => d.revenue)]).nice().range([height, 0]);
g.append('g').attr('transform', `translate(0,${height})`).call(d3.axisBottom(x));
g.append('g').call(d3.axisLeft(y).tickFormat(d => `$${d / 1000}k`));
3. Join + transitions.
g.selectAll('rect').data(data, d => d.month)
.join(
enter => enter.append('rect').attr('y', height).attr('height', 0),
update => update,
exit => exit.transition().duration(300).attr('height', 0).attr('y', height).remove()
)
.transition().duration(750)
.attr('x', d => x(d.month)).attr('width', x.bandwidth())
.attr('y', d => y(d.revenue)).attr('height', d => height - y(d.revenue));
4. Interactivity. Tooltips via a positioned HTML div (easier to style than SVG text); brush/zoom for exploration; keyboard-accessible alternatives for critical data.
5. Reusable pattern. Wrap in a function taking (selection, data, options); keep scales/axes inside; expose update by re-calling with new data.
.data(data) without keys → index join → bars morph into wrong categories on update. Always key by stable ID.viewBox + CSS width: 100%..ticks(n) responsively.role="img" + aria-label, plus a data table or textual summary for key insights..interrupt() or keyed joins to keep them coherent.import * as d3 from 'dbl' bloats bundles. Import modules: import { scaleLinear } from 'd3-scale'.아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.
로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.
아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.
Master 1Password: vaults, Watchtower, passkeys, SSH agent, CLI, and family/team administration. Use when getting full value from 1Password personally or administering it for others.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Create 3D visuals with modeling, texturing, lighting, rendering, and optimization for web and product.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Create 3D web experiences: scene setup, models, materials, lighting, animation, scroll-driven scenes, and performance budgets. Use when adding 3D to websites beyond basic demos.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Writing abstracts that get papers read — structured content, the 5-sentence core, and journal-specific constraints.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Learn effectively from courses and academies: choosing programs, studying actively, and converting courses into skills. Use when investing time/money in structured learning.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Audit designs for accessibility with WCAG checklists covering color, type, focus, motion, and content.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.