In the previous chapters, we learned how to setup highcharts library and how to create a chart with required configurations using highcharts library in our webpage. Now, we will learn how to create a scatter with regression line chart using highcharts library with examples.
Following is the example of creating a scatter with regression line chart by setting the required chart properties using highcharts library.
<title>Highcharts Scatter with Regression Line Chart</title>
text: 'Scatter plot with regression line'
name: 'Regression Line',
data: [1, 1.5, 2.8, 3.5, 3.9, 4.2],
<div id="container" style="width: 100%; height: 400px;"> </div>
If you observe the above example, we created a scatter with regress line chart using highcharts library with required properties.
When we execute the above highcharts example, we will get the result like as shown below.
This is how we can create a scatter with regression line chart using highcharts library with required properties.