Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am having some issues constructing a set analysis, to count only volume that occurred on the same day of the week as today, for the past for weeks.
For example, if today is Monday, count only Mondays for the past 4 weeks, giving me something like this.
Today (lets say is Monday) Volume = 50
Last 4 Mondays avg 45
Hi,
You can create a weekday field in your load script like: Weekday([Your date field]) as weekday,
and then you the [weekday] in the below set analysis expression for last 4 weekday average:
=Avg({$<[your date field]={">=$(=Date(Today()-28))<$(=Today())"},weekday={$(=Weekday(Today()))}>}[your measure])
Hope this helps
ZZ
Hi Jahncersantana,
You need to follow below steps
count ( { <Weekday={$(=weekday(today(1)))} , Week={">=$(=max(Week)-3)"} ,Year={$(=max(Year))} > } Quantity)
Regards,
Bhargav
Hi,
You can create a weekday field in your load script like: Weekday([Your date field]) as weekday,
and then you the [weekday] in the below set analysis expression for last 4 weekday average:
=Avg({$<[your date field]={">=$(=Date(Today()-28))<$(=Today())"},weekday={$(=Weekday(Today()))}>}[your measure])
Hope this helps
ZZ
Perfect, Thanks!!!