Skip to Main Content
Spotfire Ideas Portal
Status Future Consideration
Product Spotfire
Categories API Scripting
Created by Guest
Created on Apr 20, 2018

Apply colors only in Python

I want to be able to do through python what I can do through the GUI when I apply a coloring scheme with "colors only" to a bar chart. It seems like by default it applies by values. I want a button to be able to re-color my categorical bins when I filter down to a subset of bars on a bar chart. Below is what I am doing currently, which does not do what I want. My color axis setting is to evaluate the axis on current filtering only, which I believe is correct. I just need it to re-color by "colors only" once I filter (without manually having to go click it obviously). Can you make the colors only option available in the API?

 chart.ColorAxis.Clear()
 chart.ColorAxis.Coloring.Clear()
 chart.ColorAxis.Coloring.Apply("ColorTemplate")

  • Attach files