QoQ Line chart comparisons, stop line at current date

lookml
low_priority
done
reply
dashboards
(Conor Flanagan) #1

Hey guys,

I’m wondering if you could help me out with something. So i have this quarter over quarter line chart comparison, which is great for quarters that have finished. But if I want to bring in current quarter for a live up to date status of current performance, it flat lines after today’s date or today. Ideally I that line would stop, and each day it would tick forward or up as time goes on.

I’m pivoting by quarter, days of quarter on the x and I’m plotting a running total calculation of a ‘deal amount’ dimension.

Has anyone executed something like this? Or does anyone have any thoughts on the matter?

Much appreciated,
Stuck

0 Likes

(Brecht Vermeire) #2

Assuming you’re doing a running total here @Conor_Flanagan, you can wrap an if(is_null()) around it, for example:

depending on the availability of data:

if(is_null(${my_measure}), null, running_total(${my_measure}))

Or, evaluate depending on today’s date:

if(${date} > now(), null, running_total(${my_measure}))

Make sure you have disabled Plot Null Values in the viz edit menu, and you don’t allow discontinuities.

1 Like

(Conor Flanagan) #3

That worked!! Thanks Brecht!

0 Likes

#4

@Conor_Flanagan how did you generate the day_of_quarter timeframe? It doesn’t seem to be one of the built in timeframe options.

EDIT: found it here: Quarter-To-Date Trending by Week Index Chart

0 Likes