Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
I have historical data. I created chart with cyclic group (Week and Month).
I want to create some conditions, which show all data by Month and only dynamically last 12 weeks.
Do you have any ideas?
Thanks,
Vladimir,
If you want Monday on or earlier than 12 weeks back, it is
weekstart((date(today()-84)))
If you want it on or later than 12 weeks back:
weekstart((date(today()-77)))
Reagrds,
Michael
Thank guys,
that's I understand. But I use cyclic group Time, where Months, Weeks and Days.
I want to cut time frame for each Variable.
Thanks Michael Solomovich.
I have a question. It works, when my oDate has 1 value for each day (like 9/1/2012: 9/2/2012 ...)
But when I have oDate many value for each day (10 for 9/1/2012, 5 for 9/2/2012 ...)
My original date variable looks
9/1/2012 4:20 |
9/1/2012 8:39 |
9/1/2012 10:13 |
9/1/2012 12:31 |
9/1/2012 13:00 |
9/1/2012 17:45 |
9/1/2012 19:07 |
9/1/2012 21:47 |
9/2/2012 11:38 |
9/2/2012 13:13 |
9/2/2012 13:16 |
9/2/2012 15:47 |
9/2/2012 17:55 |
9/3/2012 2:29 |
9/3/2012 11:35 |
9/3/2012 13:13 |
9/3/2012 14:02 |
9/3/2012 15:11 |
9/3/2012 20:29 |
9/3/2012 20:55 |
9/3/2012 21:08 |
9/3/2012 22:32 |
9/3/2012 23:22 |
when I load it, I use date(original date variable) as oDate. I have 10, 5 value for each day.
iN EXPRESSION I USE
count({<oDate={"$(='>=' & WeekStart(date(today()-28))"}>}[Value])
it doesn't work.
Could you suggest anything how solve it?
Thanks again,
Vladimir,
As a rule, we don't need hours and minutes. In this case I remove them on data load:
LOAD distinct
...
date(floor(oDate)) as oDate,
...
FORM ...
Regards,
Michael
Please see my attached file. I thought the problem in oDate variable, but no.
Could you check quickly what can be?
Thanks,
How select only last 4 weeks?
Please see my attached file. I hope you find issue.
I don't know how connect my expression and dimension. I think the problem in it.
Maybe I'm wrong.
Thanks,
Hi Vladimir,
First create a variable as mentioned before called vWeeks and set value to 1.
Next create a slider where you tell in settings that Data is use by variable(s) and then select vWeeks.
Set values from 0 to for example 12 with an increment of 1.
try following expression:
count({<oDate={">=$(=Date(WeekStart(date(today()))-($(vWeeks)*7)))"},[qID_3_Task completion]={'Yes'}>}[qID_3_Task completion])/
Count({<oDate={">=$(=Date(WeekStart(date(today()))-($(vWeeks)*7)))"}>}TOTAL<WEEK> [qID_3_Task completion])
See attached file for example.
Hope this will help.
You attached my file without changes
Vladimir,
sorry. Try the new attached file. On the right side of the screen you see a slider (and a table below).
I also changed you graph.
Selecting number of weeks in slider will change you graph.
Greetings,
Marc
Yeah, I see. Thanks.
<oDate={">=$(=Date(WeekStart(date(today()))-($(vWeeks)*7)))"}
I change ($(vWeeks)*7) for days without slider.
Thank youuuuuu!!!!!