I think that's because your line chart with two dimensions translate to a straight table chart with the two dimensions ordered by you date difference, Stores, so for each date difference, the stores are listed, while you want to have a table which is ordered by Store , then date difference.
You can change this order e.g. using advanced aggregation, but the aggr() function does not allow calculated dimensions.
Can you calculate the date difference already in the script?
Ali Ahmad wrote:
So lets say I do that and named it "DaysBetween"
= aggr (
RangeSum(Above(Total Sum([Sales] * 1),0,99)), Store, DaysBetween)
I think you should remove the TOTAL qualifier, to reset the accumulation at the column segment boundery:
=Aggr( Rangesum(Above(Sum(Sales),0,RowNo() )), Store, (DaysBetween, (NUMERIC, ASCENDING)) )