Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
mrqs97
Regular Visitor

How to Create Animated Treemap with Overlapping Date Ranges

I am using the Play Axis custom visual to create an animation of a treemap. This treemap uses coloring that is based on a gradient from red to green. Essentially, the parameters of the treemap (size of boxes, colors, etc.) are all aggregates based on a specific time frame. The idea is to model the amount of red vs green on the treemap for individual timeframes.

I have used the Play Axis to animate this treemap because I want to see how it changes over time. The issue is that the Play Axis uses only individual dates and not ranges. This is an issue because individual variances between different dates are extreme, and I want to show gradual change.

What I want is overlapping ranges, where each frame in the animation removes the oldest date and inserts the newest date. Thus, if frame 1 showed a treemap aggregated from June 1 - June 5, then frame 2 should show a treemap aggregated from the dates June 2 - June 6. Is there a way to do this?

1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

 

Hi @mrqs97 

You need to add to the date table a column for the needed intervals:

Ritaf1983_0-1702097287501.png

modify needed interval

Ritaf1983_1-1702097330773.png

The column that you got will work, but on the play axis it will be formatted as a date time:

Ritaf1983_2-1702097406171.png

To solve this issue you can add a formatted column ( data type text)

Ritaf1983_3-1702097481716.png

as it is a text column you need also to modify the sort order by the date bins

 

Ritaf1983_4-1702097564571.png

now you can put the new formatted column on the play axis

Ritaf1983_5-1702097623333.png

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

 

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

1 REPLY 1
Ritaf1983
Super User
Super User

 

Hi @mrqs97 

You need to add to the date table a column for the needed intervals:

Ritaf1983_0-1702097287501.png

modify needed interval

Ritaf1983_1-1702097330773.png

The column that you got will work, but on the play axis it will be formatted as a date time:

Ritaf1983_2-1702097406171.png

To solve this issue you can add a formatted column ( data type text)

Ritaf1983_3-1702097481716.png

as it is a text column you need also to modify the sort order by the date bins

 

Ritaf1983_4-1702097564571.png

now you can put the new formatted column on the play axis

Ritaf1983_5-1702097623333.png

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

 

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors