I am having difficulty making a particular card to work.
I am attempting to make a Grouped Running Total Bar card. But instead of number values... I want the bar to represent a percentage to a total of value in particular fields.
There is one text field called Preference_Type and it contains a '1' or a '2' value, denoting Opt-Ins or Opt-Outs. I want an Opt-Out percentage of every running totals months for each `Program_id`.
So...
Total Opt-Outs/Total Preferences(Opt-Ins+Opt-Outs)
I added a `Count` field to simplify the beastmode and try various ways to make the calculation... but none of it worked. Bizarrely I would often get different graphs, even when the beastmode code essentially did the exact same thing but expressed differently.
This is an example of my Beastmode calculation...fyi, I changed the Preference_Type field to text to make this easier.
SUM((case when `Preference_Type`= '1' then `Count`*0 when `Preference_Type`='2' then `Count`*1 else `Count`*0 end) / (`Count`))
In theory, this should, for every week, take the totals of each filter's program's Opt-Outs and divide them by the total Count in that field!!!
I notice the first week is accurate, but the second week doubles the necessary Opt-Outs, and I have no idea what is going on in the thrid month, just wildly innaccurate. I know the formula is accurate because it works in an all time view that is not running total.
Does the running total graph simply just not have this kind of functionality? Does anyone have any Ideas I can do to work around this. I tried magic ETL extensively, but ultimately was unsuccessful.