Line Chart
When to use a line chart, how to configure groups and error bars, and what to consider when your data has a repeated measures structure.
A line chart displays how a continuous variable changes across time or another ordered dimension. Each point represents the mean (or a single observation) at that position on the x-axis. Points are connected by a line to emphasize the ordered progression.
Line charts are appropriate when the x-axis represents a sequence that has inherent meaning — time, dose, passage, or another ordered factor — and the progression from one value to the next is part of what you want to communicate.
Basic setup
To create a line chart, specify:
- Time or x-axis column — a numeric, date, or ordered column
- Value column — the continuous outcome variable
If your dataset contains a group column, each group is drawn as a separate line with its own color. Group names appear in the legend.
Supported x-axis types:
| Type | Example | Behavior |
|---|---|---|
| Numeric | 0, 1, 2, 4, 8 | Plotted to scale; unequal spacing is preserved |
| Date (ISO format) | 2024-01-01, 2024-03-15 | Parsed automatically; axis formatted as dates |
| Ordered category | week1, week2, week3 | Plotted in data order; equally spaced |
Error bars
Error bars can be added to show variability or uncertainty at each time point. Licklider calculates them per group per time point.
| Type | What it shows |
|---|---|
| SEM | Precision of the group mean at that time point |
| SD | Spread of individual observations at that time point |
| 95% CI | Confidence interval around the group mean, using t(n−1, 0.025) × SEM |
Error bar type can be set in the Inspector or via Chat. When no error bar type is specified, the line is drawn without error bars.
For guidance on which error bar type to choose, see Group Comparison Mean and SEM.
These bar types answer different questions. SD describes spread among observations, SEM describes precision of the mean estimate, and 95% CI is a directly interpretable uncertainty interval around the mean. A line with SEM or CI bars can therefore look much more stable than the underlying data if readers assume the bars show subject-to-subject variability.
What the Inspector shows
When a line chart is active, the Inspector displays a summary table of the mean and variability at each time point, broken down by group:
| Column | Description |
|---|---|
| Group | Group name (blank if no group column) |
| Timepoint | x-axis value |
| n | Number of observations at that time point |
| Mean | Group mean at that time point |
| SD / SEM | Depending on selected error bar type |
This table provides the values needed to report results without reading numbers off the figure.
Repeated measures data
Line charts are frequently used with repeated measures data — datasets where the same subject, animal, or sample is measured at multiple time points. This structure requires care.
The line chart shows group means, not individual trajectories. When each subject is measured repeatedly, the group mean line summarizes what happened on average. It does not show whether individual subjects followed the same pattern, crossed over, or diverged — information that may be critical to your interpretation.
When Licklider detects a subject or ID column alongside multiple time points, it will suggest showing individual trajectories. Until a Spaghetti Plot is available, enabling individual data point overlay is the closest alternative.
Pseudoreplication risk If the same biological unit is measured multiple times but treated as independent observations in the group mean calculation, the error bars will be too narrow and any associated statistical test will be anti-conservative. Licklider checks for this condition and will surface a warning if the data structure suggests that repeated measurements from the same unit may not be accounted for.
Licklider cannot detect this reliably if the subject ID column is missing, mapped incorrectly, reused inconsistently, or aggregated away before the data reaches the figure. In that case, the mean line and its error bars may look more precise than the study design actually supports.
Missing time points
If an observation is missing at a particular time point, that point is excluded from the group mean calculation at that time point. The line will show a gap where no data exists for that group at that time.
Licklider does not interpolate across missing time points. If your data has irregular or missing coverage, consider whether a line connecting non-adjacent time points accurately represents the progression you intend to show.
This is intentional. Interpolating missing time points can make the path look smoother and more certain than the observed data justify, especially in sparse or irregular longitudinal designs.
Display controls
The following can be adjusted from the Inspector or Chat:
| Control | Options |
|---|---|
| Error bars | SEM / SD / 95% CI / None |
| Individual data points | On / Off |
| x-axis label | Editable directly in Inspector |
| y-axis label | Editable directly in Inspector |
| Axis scale | Linear / Log |
| Axis range | Min and max |
| Group order | As-is / Custom |
When to use a line chart
Line charts work well when:
- The x-axis is time or another ordered dimension
- You want to show the trajectory of group means over that dimension
- The progression between consecutive points is meaningful
- n per group per time point is sufficient to estimate the mean
Consider alternatives when:
- You want to show individual subject trajectories alongside or instead of the group mean — use a Spaghetti Plot (not yet available; see repeated measures guidance above)
- You have only two time points and the comparison is the primary focus — use a paired analysis with a before-after plot or a Group Comparison Mean figure
- The x-axis is not ordered and the connection between points has no meaning — use a Scatter Plot or Bar Chart
- n per time point is very small — show individual data points and interpret group means with caution
Design rationale and references
Licklider positions line charts as ordered-progression figures because connecting points visually implies continuity or sequence. That implication is appropriate for time, dose, passage, and other ordered axes, but it is misleading when the x-axis is unordered.
The page also emphasizes repeated-measures structure because a mean trajectory can hide subject-level crossing, divergence, or uneven response patterns. In longitudinal data, the average line is often useful, but it is not a substitute for checking whether individual subjects behave consistently enough for that summary to be trusted.
Licklider avoids automatic interpolation across missing time points for the same reason. Filling gaps visually would add an implied path that was not actually observed.
References
- Weissgerber, T. L., Milic, N. M., Winham, S. J., & Garovic, V. D. (2015). Beyond bar and line graphs: time for a new data presentation paradigm. PLOS Biology, 13(4), e1002128. https://doi.org/10.1371/journal.pbio.1002128
- Cumming, G., Fidler, F., & Vaux, D. L. (2007). Error bars in experimental biology. The Journal of Cell Biology, 177(1), 7-11. https://doi.org/10.1083/jcb.200611141
What this page does not cover
- Individual trajectory plots — Spaghetti Plot (not yet available; see repeated measures guidance above)
- Repeated measures statistical analysis — see Repeated Measures and Mixed Models
- Paired comparisons at two time points — see t-Test (paired)
- Assumption checks for repeated measures — see Paired vs Unpaired Guard, Pseudoreplication Detection