I'm new to Tableau so I'm still learning.
So I have a basic graph. From the parameter, the user can choose to display the data in either a line graph or a slope graph. They can also filter on date range and location. It's basically a graph showing visits by location. The slope graph is just a straight line from the first point to the last point, depending on the date range the user chose.
If the slope graph is chosen, I need to display the numerical, calculated value of the slope somewhere on the graph, in addition to the line. The equation would be (y2 - y1) / (x2 - x1) but how do I calculate the slope in Tableau, when the date range and location can vary?