There may be times where you’re looking to compare a chart’s results against a certain data point. You can do this by adding a target line to your chart by using Annotations or creating a target column in your chart.
You can easily add an Annotation to your chart via a chart’s Settings if you prefer to add a static target value. Annotations can be especially useful if your chart has a dual axis or contains a large number of columns.
Another option is to directly add your target amount within your chart as a separate Target column.
In the following example, we created a Bar chart that outlines the number of users per month using our Demo Data Source. We have a goal of 5,500 users per month and would like to visualize our progress against this goal.
If your target value is already available within your database, you can simply add the column to your chart’s query. If that data doesn’t exist in your database, you can create a new column using an Add Column Pipeline Step and selecting Custom formula from the Formula Type dropdown. You’ll then assign a static value to the column in the Formula field (e.g. 5500) that will show as the benchmark for every time period.
We recommend setting the chart type to a Bar Line chart to allow your target line to show up as a line and differentiate it from the rest of your data.
Customize your target line
Once your target line is set, you can also customize how the line will be displayed on your chart via the Series tab in the chart Settings. From there, you can set a thicker line width, choose to show dots or not on the line, and even set how the line looks by clicking the Use custom styles checkbox and selecting the desired line style.
Make sure to click Done and save your chart once you’ve completed editing it.