How to Add Line of Best Fit in Google Sheets

How to Add Line of Best Fit in Google Sheets

The line of best fit, also called Trendline in Google Sheets, helps shows the relationship between two variables.

It is used to make predictions and understand trends in your data. For example, if you know that a certain number of people use your product each day, you can use a trendline to predict how many people will use your product in the future.

In Google Sheets, you can add a line of best fit to a scatterplot. This guide will show you how.

Step 1: Create your scatter plot

  1. Select the data you want to include in the scatter plot.

    Select Data
    Select your data.

  2. From the “Insert” menu, select Chart.

    Select Insert > Chart.

  3. Your chart will automatically be made. Double-click it, and a Chart editor panel will appear on the right side. In the Chart type dropdown, select Scatter chart.

    Scatter Chart
    Select Scatter chart as your chart type.

Step 2: Add the line of best fit

  1. Double-click your scatter chart. The Chart editor will appear on the right.

    Chart Editor
    Open the Chart Editor.

  2. In the Customize tab, select the Series dropdown.

    Select Series

  3. Next, check the box next to Trendline.

    Check the box next to Trendline.

  4. A trendline (line of best fit) will be made for your scatter plot.

    Trendline in Scatter Chart
    Trendline displays in your scatterplot.

Step 3: Customize the line of best fit

Under the Trendline checkbox, there are various options to customize the trendline.

Customize Trendline
Customize the trendline.

Change the Type of trendline: By default, the Linear trendline is reflected on the chart. But you can choose among the different types of trendlines in Google Sheets:

  • Linear: shows the general direction in which a series of data is moving.
  • Exponential: used when data is growing at an exponential rate.
  • Polynomial: used when data has ups and downs.
  • Logarithmic: used when the data has a sharp fall and rise.
  • Power Series: used when data increases or decreases at a specific rate.
  • Moving Average: used when data has extreme values.

You can also change the:

  • Line color.
  • Line opacity.
  • Line thickness.
  • Label (title of your trendline)
  • Whether to display the R-squared value.

Phoebe is an HR assistant in her day job, but is also a web blogger that loves writing guides and sharing her experiences. When she is not out with her friends, she enjoys traveling or binge-watching Netflix. She graduated with a BA in Communication and Media Studies from the University of Utah, and is a chief editor at TechObservatory.

Leave a Comment