설명 / Description
선 그래프는 정렬된 데이터 포인트를 선분으로 연결하여 눈이 자연스럽게 따라갈 수 있는 연속적인 시각적 경로를 만듭니다. 수량 값이 연속적인 차원 — 가장 흔하게는 시간 — 에 따라 어떻게 변하는지 보여주는 기본 선택지입니다. 두 점 사이의 선 기울기는 변화율을 즉시 전달하며, 전체적인 모양은 추세, 주기, 이상치를 드러냅니다.
The line graph connects ordered data points with line segments, creating a continuous visual path that the eye naturally follows. It is the default choice for showing how a quantitative value changes over a continuous dimension, most commonly time. The slope of the line between two points immediately communicates rate of change, while the overall shape reveals trends, cycles, and anomalies.
선 그래프는 연속성이라는 게슈탈트 원리를 활용합니다: 시청자는 연결된 점들을 공간을 이동하는 하나의 개체로 인식하여, 시리즈를 추적하고 궤적을 머릿속으로 추정하기 쉬워집니다. 같은 축 위의 여러 선은 그룹 간 추세를 직접 비교할 수 있게 해주지만, 겹치는 시리즈가 5~7개를 넘으면 가독성이 떨어집니다.
Line graphs exploit the Gestalt principle of continuity: viewers perceive the connected points as a single entity moving through space, making it easy to track a series and mentally extrapolate its trajectory. Multiple lines on the same axes enable direct comparison of trends across groups, though legibility degrades beyond 5-7 overlapping series.
x축은 보통 연속적이거나 순서가 있는 차원(시간, 순서)을 나타내고, y축은 측정된 수량을 나타냅니다. 막대 차트와 달리 선 그래프의 y축은 절대적인 크기보다 상대적인 변화를 강조하는 경우 반드시 0에서 시작할 필요는 없지만, 시청자를 오도하지 않도록 신중하게 다뤄야 합니다.
The x-axis typically represents the continuous or ordinal dimension (time, sequence), while the y-axis represents the measured quantity. Unlike bar charts, the y-axis of a line graph does not strictly need to start at zero if the emphasis is on relative change rather than absolute magnitude, though this should be done carefully to avoid misleading viewers.
프롬프트 예시 / Prompt Examples
다음 프롬프트를 Claude, ChatGPT 또는 다른 AI 도구와 함께 사용해보세요:
Try these prompts with Claude, ChatGPT, or other AI tools:
"2020년부터 2024년까지 월별 사용자 수 추이를 선 그래프로 그려주세요."
"Create a multi-line chart showing temperature trends for 3 cities over the past decade."
"Plot monthly revenue as a line chart with a trend line and confidence interval shading."
언제 사용하나 / When to Use
- 시간에 따른 추세, 패턴, 궤적을 보여줄 때(주가, 기온, 지표 등)
- Showing trends, patterns, or trajectories over time (stock prices, temperature, metrics)
- 같은 기간 동안 여러 시리즈가 어떻게 변화하는지 비교할 때
- Comparing how multiple series evolve over the same time period
- 변화율, 가속도, 변곡점을 강조할 때
- Highlighting rates of change, acceleration, or inflection points
- 점들 사이의 보간이 의미 있는 연속 데이터를 표시할 때
- Displaying continuous data where interpolation between points is meaningful
이럴 땐 피하세요 / When NOT to Use
- 서로 관련 없는 범주 간 값을 비교할 때 -- 막대 차트를 사용하세요
- Comparing values across unrelated categories -- use a bar chart
- x축 범주에 의미 있는 순서가 없을 때 -- 순서 없는 점을 연결하면 잘못된 연속성을 암시합니다
- When the x-axis categories have no meaningful order -- connecting unordered points implies false continuity
- 단일 변수의 분포를 보여줄 때 -- 히스토그램이나 박스 플롯을 사용하세요
- Showing distributions of a single variable -- use a histogram or box plot
- 데이터 포인트가 매우 적을 때(2~3개) -- 막대 차트가 비교를 더 명확하게 전달할 수 있습니다
- When you have very few data points (2-3) -- a bar chart may communicate the comparison more clearly
구조 / Anatomy
- 선 마크: 데이터 포인트를 관통하는 연결된 경로로, 추세를 인코딩합니다.
- Line mark: The connected path through data points, encoding the trend.
- 데이터 포인트(점): 각 관측치에 표시되는 선택적 마커입니다. 데이터가 희소할 때 유용하며, 밀집된 시리즈에서는 흔히 숨겨집니다.
- Data points (dots): Optional markers at each observation. Useful when data is sparse; often hidden for dense series.
- X축: 연속적이거나 순서가 있는 차원(보통 시간)입니다.
- X-axis: The continuous or ordinal dimension (usually time).
- Y축: 수량 측정값입니다.
- Y-axis: The quantitative measure.
- 범례: 여러 시리즈가 하나의 차트를 공유할 때 필요합니다. 선 끝점에 직접 레이블을 다는 것이 별도 범례보다 더 명확한 경우가 많습니다.
- Legend: Required when multiple series share the chart. Direct labeling at line endpoints is often clearer than a separate legend.
- 격자선: 수평 격자선은 독자가 값을 추정하는 데 도움을 주며, 수직 격자선은 덜 흔합니다.
- Grid lines: Horizontal grid lines help readers estimate values; vertical grid lines are less common.
- 주석: 정점, 저점, 주목할 만한 사건에 대한 콜아웃이 맥락을 더해줍니다.
- Annotations: Callouts for peaks, troughs, or notable events add context.
변형 / Variations
- 다중 시리즈 선 그래프: 그룹 비교를 위해 같은 축 위에 여러 선을 그립니다.
- Multi-series line graph: Multiple lines on the same axes for group comparison.
- 계단형 선 차트: 대각선 대신 수평/수직 선분을 사용하며, 값이 변화 사이에 일정하게 유지될 때(예: 요금제 등급, 이산적 상태 변화) 적합합니다.
- Step line chart: Uses horizontal and vertical segments instead of diagonal lines, appropriate when values hold constant between changes (e.g., pricing tiers, discrete state changes).
- 스파크라인: 축과 레이블을 없앤, 단어 크기만 한 작은 선 그래프로, 텍스트나 표 안에 인라인으로 삽입됩니다.
- Sparkline: A small, word-sized line graph stripped of axes and labels, embedded inline in text or tables.
- 기울기 차트(슬로프그래프): 두 시점만 있는 선 그래프로, 시작 상태와 끝 상태 사이의 변화에 초점을 맞춥니다.
- Slope chart (slopegraph): A line graph with only two time points, focusing on the change between a start and end state.
- 범프 차트: y축이 값이 아니라 순위를 보여주는 선 그래프로, 시간에 따라 순위가 어떻게 바뀌는지 추적합니다.
- Bump chart: A line graph where the y-axis shows rank rather than value, tracking how rankings shift over time.
코드 레퍼런스 / Code Reference
// Observable Plot - multi-series line graph
Plot.plot({
marks: [
Plot.lineY(data, {
x: "date",
y: "value",
stroke: "series",
tip: true
}),
Plot.ruleY([0])
],
x: { type: "time", label: "Date" },
y: { label: "Value" },
color: { legend: true }
})