Change order of groups in heatmap dynamically


#1

Hello Im using a Heat Map and sometimes i need to change the order of the groups dinamically in order to see a transposed Heat Map, the way I do this is by getting the visualization, changing the query and running the visualization query again, I wonder if there is a better way to do it without requerying since the data is there, i just need to transpose it


#2

Hey @mdemian, yes there is a way to do that, you just have to set the property transpose in true and then execute the visualization with a boolean argument to indicate that you don’t want to requery, also you can review the documentation of the property here: Heat Map transpose, this is an example:

myHeatmap.set('transpose', true) // transposed values
         .execute(false) // executing with no query

#3

Man that is super easy, and it works, so thank you so much.