1 3 4 5 6 7 8 113 Replies Latest reply on Feb 13, 2019 7:29 PM by Selvi velraj Go to original post
• ###### 60. Re: Sankey diagram made of dynamically generated polygons

So, please correct me if I'm wrong. If I have a dataset that has 100000 rows, does that mean that I will have a 9.8 million rows after joining it to the model?

• ###### 61. Re: Sankey diagram made of dynamically generated polygons

That's true.

Except if you apply the dedensification technics I described in a previous post.

• ###### 62. Re: Sankey diagram made of dynamically generated polygons

Thank you.

• ###### 63. Re: Sankey diagram made of dynamically generated polygons

Hi Olivier!

Your Superstore Interactive Sankey looks great!! Do you have a step-by-step approach on how to create this?

Thanks!

-a

• ###### 64. Re: Sankey diagram made of dynamically generated polygons

Hadoop/Hive for the model. Forgive the mess, didn't spend a whole lot of time making it streamlined but it gets the job done. Replace "<INSERT TABLE HERE> " with any table in your databse.

select table1.link, table2.t, table1.min_max as min_or_max, table1.path

from

from(

select b.link,b.min_max, b.path, row_number() over() as row_num2

from

(select a.link, a.min_max, a.row_num as path

row_number() over() as row_num,

'max' AS min_max

from <INSERT TABLE HERE> limit 100) a

where a.row_num <= 98

and a.row_num >= 50

order by a.row_num desc) b ) c ) table1

left join

from (select concat(a.link, a.row_num) as link_t, (1/4) * (a.row_num - 25) as t

from

row_number() over() as row_num

from <INSERT TABLE HERE>) a

) b

where b.t >= -6

and b.t <= 6 ) table2

union all

select b.link, b.t, b.min_max as min_or_max, row_number() over() -1 as path

from (select a.link as link, (1/4) * (a.row_num - 25) as t, a.min_max

from

row_number() over() as row_num,

'min' AS min_max, row_number() over() as path

from <INSERT TABLE HERE>) a

) b

where b.t >= -6

and b.t <= 6

• ###### 65. Re: Sankey diagram made of dynamically generated polygons

Thanks Victor. This is great.. can't wait to try this out! I was planning on writing a PL/SQL procedure to populate an Oracle table for my dashboard. I would prefer a non-physical solution like this for sure.

• ###### 66. Re: Sankey diagram made of dynamically generated polygons

Ricky,

Did you ever get the highlighting across multiple worksheets (more than three seems to be an issue) in a dashboard issue figured out? I am having the same problem.

Ian

• ###### 67. Re: Sankey diagram made of dynamically generated polygons

Hi,

I've been battling with building a Sankey in Tableau for a few days and I feel like your guide might be the way forward for me.

Can you please explain what the Min and the Max field is? I'm a little unsure.

Regards,

Bree

• ###### 68. Re: Sankey diagram made of dynamically generated polygons

Nice and thanks for sharing this !

• ###### 69. Re: Sankey diagram made of dynamically generated polygons

This is fantastic, I'm a relative novice at tableau but these instructions were very clear and easy to follow! I'm now able to trick people into thinking i'm some sort of Tableau Wizard! The question of highlighting across multiple sheets has come up a few times, does anybody have an answer to this? At the moment I'm only able to highlight adjacent worksheets. So currently if I hover over the start bar, the corresponding step lines in the sankey are highlighted, and if i hover over the end bar, the corresponding lines in the saneky are highlighted.Is there any way to get all three sections to highlight? Thanks, Harry

• ###### 70. Re: Sankey diagram made of dynamically generated polygons

Hi Oliver! I'm trying to update the visualization so Level 1 > Level 2 ignores all other Levels. Similarly for Level 2 > Level 3. I tried to update the table calculations for the position calculated fields but this isn't working. Do you have any tips to achieve this?

• ###### 71. Re: Sankey diagram made of dynamically generated polygons

Hi Oliver,

I'm trying to rebuild the graph and I don't understand how the "Size" were allocated? Unfortunately I cannato understand the logic. Could you be so kind please to give me any short explanation.

Best

Dilyana

• ###### 72. Re: Sankey diagram made of dynamically generated polygons

Hi Olivier,

Thank you so much for this post. I followed your tutorial, but I made the same error as Thorsten. Tried to find the difference between my file and your SANKEYTESTcorrect file (the sort on the sum of payments field), but just can't find my error. (I can't figure out how to open the correct table calculation window to find where to uncheck the sort). I am very new to Tableau, so I'm sure this is really simple). Any help would be most appreciated.

Thanks again for the immensely helpful tutorial and files!

Megan

• ###### 73. Re: Sankey diagram made of dynamically generated polygons

Sort options can be changed in Field > edit> default table calculation> advanced

• ###### 74. Re: Sankey diagram made of dynamically generated polygons

If anyone is wondering why is getting such result: check if min/max column numbering starts with 0 not 1

1 3 4 5 6 7 8