Please attach a Tableau Packaged Workbook including sample data.
slope is defined as change in Y over change in X. so use your calculated field to determine first if you slope is or . Once you have that calculated field with results ranging from , 0, or create another calculated field that says
IF [slope] > 0 THEN "Positive"
ELSEIF [slope] <0 THEN "Negative"
ELSEIF[slope] = 0 THEN "0"
Drag this calc field onto the color shelf and pick you colors.
yes but is there a formula that will compute slope over a given date range
Is it a line with two endpoints or multiple ups and downs (from day to next day?) if the latter you could always use a LOOKUP function to look back in the viz one and see if the value is more or less than the current. if you only have one line (two points) you could use a difference between WINDOW_MAX and WINDOW_MIN.