1 Reply Latest reply on Nov 11, 2016 9:54 AM by diego.medrano

    Coloring Marks by Multiple Dimensions in Public

    Michael Cisneros

      Just sharing an experience that I just had when adding a workbook to Public. 

       

      I had a horizontal bar chart that had both negative and positive values, so the midpoint of the x-axis was the zero baseline.  Some of the bars went to the right (positive values), some went left.

       

      I wanted these bars to be colored based on TWO different dimensions:

       

      - Was the bar a positive value or a negative value?

      - Was the bar EXPECTED to be positive or negative (based on a calculated boolean field)?

       

      The first dimension determined if the color was blue or red, and the second determined if the color was light or dark.

       

      This looked exactly as I expected it to in Desktop.  Imagine my surprise when I uploaded my workbook to Public, and my colors were not as I had selected them to be. The default Tableau palette's yellow/gold color had appeared, in place of my light red. (None of the bars in my current view qualified to be dark red.)

       

      Well, I reloaded the workbook about 10 different times, tinkering with various colors and settings all the while, and I could not get the colors to be correct.

       

      Finally, I created another calculated field that had IF...ELSEIF....ELSEIF....ELSE statements, and set that calculated field to be the sole dimension for coloring bars. Only then did my chosen colors persist from creation through Public upload.

       

      So the moral of the story is: just because you CAN set two different dimensions to be "Color" dimensions in the Marks card, do NOT expect your colors to work properly when you put your workbook on Public. Create a Calc Field with all your multidimensional logic inside of it, and use that instead.