You can show trend lines in a visualization to highlight trends in your data.
To add trend lines to a view, both axes must contain a field that can be interpreted as a number. For
example, you cannot add a trend line to a view that has the Product Category dimension, which
contains strings, on the Columns shelf and the Profit measure on the Rows shelf.
However, you can add a trend line to a view of sales over time because both sales and time can be
interpreted as numeric values.
Reference: https://help.tableau.com/current/pro/desktop/en-us/trendlines_add.htm