4 Replies Latest reply: May 20, 2016 9:13 AM by David Lyness RSS

    Stacked bar chart colour query

    David Lyness

      Hi All,

       

      I have a dimension (Occupation) that appears on 3 or 4 separate charts throughout my dashboard. I have set up a variable called vColourOccupation which has the following if statement:

       

      if(Occupation='MI Lead',RGB(51,102,255),
      if(Occupation='Operations Head',RGB(255,51,102),
      if(Occupation='Population Lead',RGB(51,255,204),
      if(Occupation='Quality Assurance',RGB(245,184,0),
      if(Occupation='Relationship Owner',RGB(77,153,0),
      if(Occupation='Review Analyst',RGB(153,0,0),
      if(Occupation='Team Lead',RGB(0,255,255),
      RGB(0,0,0))))))))

       

      In the background colour piece of the expression I have put the variable in here. However when I do this and open my dashboard it looks like the following:

       

       

      Whenever I select one of these bars and unselect it then it fixes this issue and looks like the following:

       

       

      Anyone any ideas why this would be? The expression is the following:

       

      //Baseline

      sum({<YearQ={'2017-1','2017-2','2017-3','2017-4'}, Attrition=, Retirement=>}[Demand C])



      +
      sum({<Year={'2018'}, Attrition=, Retirement=>}[Demand C])*vMixD2014
      +
      sum({<Year={'2019'}, Attrition=, Retirement=>}[Demand C])*vMixD2015
      +
      sum({<Year={'2020'}, Attrition=, Retirement=>}[Demand C])*vMixD2016
      +
      sum({<Year={'2021'}, Attrition=, Retirement=>}[Demand C])*vMixD2017
      +
      sum({<Year={'2022'}, Attrition=, Retirement=>}[Demand C])*vMixD2018


      +
      sum({<Year={'2018'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2014)
      +
      sum({<Year={'2019'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2015)
      +
      sum({<Year={'2020'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2016)
      +
      sum({<Year={'2021'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2017)
      +
      sum({<Year={'2022'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2018)


      //Variables

      +
      sum({<Year={'2017'}, Attrition=, Retirement=>}[Demand C])*vMixD2014*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2018'}, Attrition=, Retirement=>}[Demand C])*vMixD2014*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2019'}, Attrition=, Retirement=>}[Demand C])*vMixD2015*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2020'}, Attrition=, Retirement=>}[Demand C])*vMixD2016*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2021'}, Attrition=, Retirement=>}[Demand C])*vMixD2017*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2022'}, Attrition=, Retirement=>}[Demand C])*vMixD2018*(vNewClients - vAutomation + vRisk + vRegulation)

      +
      sum({<Year={'2017'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2014)*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2018'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2014)*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2019'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2015)*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2020'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2016)*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2021'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2017)*(vNewClients - vAutomation + vRisk + vRegulation)
      +
      sum({<Year={'2022'}, Attrition=, Retirement=>}[Demand F])*(1-vMixD2018)*(vNewClients - vAutomation + vRisk + vRegulation)

       

      Would anything here be affecting it?