The line chart is a perfect fit in case you want to track and trace the evolution of a specific quantitative value. It is frequently used to show trends and to analyze how the data has changed over time. You can also compare data from multiple values or categories by having multiple lines. Let’s dive into more detail!

The line chart

Line charts are created by first plotting data points on a grid and then connecting a line between all of these points. The y-axis displays the quantitative value, while the x-axis shows a timescale or a sequence of intervals. Negative values can be displayed below the x-axis.

The direction of a line on the chart works as a nice metaphor for the data - an upward slope indicates that the value has increased and a downward slope indicates that the value has decreased. The line's journey across the graph can create patterns that reveal certain trends.

Chart creation

The line chart can be found underneath the ‘line charts’ section. You can add it to the editor by clicking on it or by drag and drop. There are three data slots to add data to - ‘X axis‘, ‘measure’ and ‘group by’.

X axis

Date or date time columns are a perfect fit for this slot, which defines the displayed time frame or period for which the chart shows data.

In the example below, the month level of a date column is used. Of course, all other levels are also possible depending on your data.

Measure

The measure slot defines the numeric value for a specific point in time. The higher the value, the higher the data point on the grid. Different aggregations can be set via the slot settings in order to be able to display different calculations over time, e.g. the average or distinct count.

Via the axes-settings of the chart, the measure axis type can be changed from linear to logarithmic (base 2 or base 10), which will filter out all measure data lower than zero.

In the example, the numeric column ‘amount’ is used to indicate for how much value products are sold over the years.

Group by

Columns with data type ‘hierarchy’ are a perfect fit for this slot.

When adding data to it, multiple lines will appear to enable you to compare different values from different categories. This is really powerful and gives you enhanced insights in your data, trends and evolution over time.

Make sure not to have too many lines on the chart. It looks messy and it is difficult to analyze. A perfect grouped line chart exists of maximum five lines.

The example shows the evolution over time of the volume sold per product. By adding a filter, you can choose which products you would like to compare.

Tips and tricks

The line chart has plenty of possibilities to customize it to your styling needs:

  • Monotone line interpolation to make it look smoother;

  • Break the line of add a manual value for time periods without data;

  • Change the color if the axis;

  • Remove or adapt the density and styling of ticks on the axis, replace them with gridlines. Or change the format from Auto to User defined. As such, the label will reflect the exact format of the date level you've chosen (date, month, quarter, etc.);

  • Enable markers on the data points;

  • Choose logarithmic measure scales.

This chart can be filtered via the Brush filter by default. You can use this filter by clicking and dragging on an area of the chart. The "Clear filter" button will return the dashboard to the initial, unfiltered state. You can also disable the "Brush filter" in the "Interactivity" section of the chart settings.

The legend in this chart can be used to show or hide specific elements by clicking them.

Video Tutorial

Similar charts

Charts similar to the line chart are the area chart and stacked area chart.

Need more information?

Do you still have questions? Let us know how we can help.
Send us feedback!