3 Replies Latest reply on Apr 14, 2018 11:15 AM by Jim Dehner

    Conditional color formatting and paramters

    Parimal Pandey

      Hi all,

      Need some help with my viz where i am struggling a bit with the color formatting.


      I have a parameter where user can select from some options (ex: apples,oranges,banana) then i create a calculated field to count number of instances wrt each item.

      I also put fruit type to the color mark so based on the selection trend lines change the color.

      This goes fine but with a glitch, the trend is plotted correctly for the selection but a line is plotted always for the type which are not selected. This is always a flat line with 0 value but is always there.

      How can i get rid of this line at the bottom of chart


        • 1. Re: Conditional color formatting and paramters
          Jim Dehner



          I think I understand but not certain without seeing your twbx workbook with the data


          You say you have a calculated field that counts the incidences for the "fruit' in the parameter

          but then you  drag all fruit to the color tile? or did you drag the calculated field to the color tile?


          if you calculation is something like if [fruit]=[fruit parameter] then count(incident) else 0 end


          try leaving off the 'else 0' and let if fill in nulls (they wont plot)


          if you are using Fruit on the color tile use a create another calculation for color code based on the parameter something like

          if [fruit parameter]='Banana' then 'yellow'

          elseif [fruit parameter] = 'Apple' then 'red'

          and so on


          and drag that to the color tile - you will need to edit the color appropriately



          If this posts assists in resolving the question, please mark it helpful or as the 'correct answer' if it resolves the question. This will help other users find the same answer/resolution.  Thank you.

          1 of 1 people found this helpful
          • 2. Re: Conditional color formatting and paramters
            Parimal Pandey

            thank you , this resolved my issue

            • 3. Re: Conditional color formatting and paramters
              Jim Dehner

              Thank you - glad to help out

              if it solved your issue - please mark my response correct to close the thread