mattflor / chorddiag

R interface to D3 chord diagrams
158 stars 44 forks source link

Adding another dimension of data? #42

Open wcwr opened 3 years ago

wcwr commented 3 years ago

A really wonderful and helpful package, thanks!

I've followed the examples, reviewed the documentation, and generated plots using my own data, so I think feature I'm asking about is unsupported by please let me know if I'm mistaken.

I'd like to know if there is any way to relate one of the parameters like colors/line thickness/font color/ etc. to another dimension of data. Currently, my bipartite matrix edge thickness is directly tied to the values of the corresponding matrix - and this is beautiful. But I'd like to add another dimension - let's say by scaling the colors.

So Imagine I have a separate matrix (matrix2) which has the exact same row/col names as my original matrix, but different values. Is there a way that I could make the edge colors something like a heatmap? So the final plot would have the edge thickness corresponding to the first matrix, and the edge colors corresponding to second matrix.

Thanks!