A Linear Regression line can be applied to price or another indicator. Linear Regression lines are drawn backward from the most recent bar. The length of the line is the period specified. (On a Daily chart, a period of 30 would mean that the Linear Regression line is 30 days long.)
Linear Regression fits the best average line between any two points, thereby showing the trend clearly and accurately.
Linear regression lines on price and an indicator can help you spot divergences. The daily chart of DRI below has 50 day linear regression lines on price and TSV. Price has been trending down while TSV is trending up showing a positive divergence.