Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I have a chart where Bar is showing Dollar valuer per month. And in Line we need show the Trendline Average.
If I use the Trendlines property it is simply dividing by 12. Instead of that I need Sum(Dollar) / Available Month in Current Year.
Is there any other property to do the same.
Thanks,
Sarif
I am attaching the Sample App.
There seems to be 9 months using this
=Count( DISTINCT{<CstFiscalYear = {'2016'}>}CstFiscalPeriod)
So, 6871552.9059/9 = 763505.88
Changed the PY Expression to this
=If(sum(WIPYieldLoss) > 0, Avg({<CstFiscalYear = {'2016'}>}TOTAL Aggr(Sum({<CstFiscalYear = {'2016'}>}WIPYieldLoss), CstFiscalPeriod)))
Does this look right?
Hello Sunny... not exactly... This doing Sum(Dollar) for CY/12, instead of that I want Sum(Dollar) for CY/8.
As my dashboard is showing 8 months for 2017.
Please help.
Thanks,
Sarif
For your current selection, what is the average number you are expecting to see (provide a numeric number)?
Avg should be 104042436.5 for 2017 selection.
832339492/8= 104042436.5
next month it should be divided by 9.
Thanks for your help.
Thanks,
Sarif
So, then why did you think that selecting Average Trend Line was not working? To me it seems to be working (bottom chart). Also, added an expression (above chart), but would not recommend using it (unless you have to for ignoring selections reason, in which case the below expression will have to be modified)
=If(sum(WIPYieldLoss) > 0, Avg(TOTAL Aggr(If(sum(WIPYieldLoss) > 0, Sum({<CstFiscalYear = {'2017'}>}WIPYieldLoss)), CstFiscalPeriod)))
Average Trendline will always give total value / 12, right?
Fot Prior Year, it is ok.. but for Current Year we need No month should be actual.
Is my understanding correct?
Thanks,
Sarif
From what I am seeing, it is not... and in general it only gives the average based on what ever is shown on the chart. Right now there are 8 points, so it should show average based on 8 points only. The line is above 100,000,000.... doesn't that seems to be doing the right calculation?
Hello Sunny,
I am using below script:
=(If(sum(WIPYieldLoss) > 0, Sum(TOTAL Aggr(Sum({<CstFiscalYear = {'$(v_CurrentFiscalYear)'}>}WIPYieldLoss), CstFiscalPeriod))))/
(count(distinct Left(DateCompleted_Key,6)))
But the division part is not working. Instead of that if I use 8, it is working. And
count(distinct Left(DateCompleted_Key,6)) is also separately showing 8 in Text box.
Am I missing anything?
Please help.
Thanks,
Sarif
Hello Sunny,
I just applied your logic for CY and PY. It is coming correct when I select Year = 2017.
But I want two line should be constant if I select Year = 2016 also.
In the attached App, if I select 2016, then PY is not geting changed. But CY is changing.
I want both of them should be fixed.
Please help.
Thanks,
Sarif