In a line chart, measures and dimensions are taken along the two axes of the chart area. Line Chart is used to understand the moment of the data and analysis its movement from one value to the other. In bars, we have seen that the length was the measure of communication. We can differentiate the line chart with size thick line, thin line and also with colors. The pair of values for each data becomes a point that joins to create a line which shows the disparity or connection between the selected dimensions and measures.
The widespread application of a line chart is generally with time series data as it has values which are moving over time so though you can do it for almost every data, but they are usually acting as a good practice for time-series data.
Simple Line Chart
A simple line chart is very easy to create. The following steps depict the way to create a simple bar chart:
- From the Microsoft Excel option, choose your excel file. Unlike here, we have chosen Facebook 2019 data.
- Now you have to select one dimension and measure. Choose the dimension, drag it (we have taken Years) to the columns shelf. And the measures (we have taken sales) to the rows shelf.
- Under the marks card, select the line chart.
- You will get the resulting line chart, which shows the variation of Sales over distinct years.
- You can also manage the size and thickness of the line chart by selecting the size option under the marks card.
- By dragging the rectangular bar left or right, you can increase or decrease the thickness of your line. In the resulting screenshot, we have dragged it to its right in order to increase its thickness.
Multiple Line Charts
Tableau allows you to add other measures on the rows shelf to generate multiple line chart on the same sheet pane.
Drag one dimension to columns shelf and two or more measures on the rows shelf.
This will produce two line charts, each in one pane as shown in the resulting screenshot. Each pane represents the distinction of the dimension with one of the specified measures.
Line Chart with Distinct Paths
In Tableau, under marks card, there is a Path option which allows you to choose your Line path. It supports the following three Line Type paths.
- Linear Line Path
It is the straight line which is formed by joining the two points as shown above.
- Step Line Path
In this, the line path will be represented in steps as shown in the following screenshot.
- Jump Line Path
In line path, we have horizontal nuclear lines which are segregated from each other.