D3partitionR icon indicating copy to clipboard operation
D3partitionR copied to clipboard

set_continuous_color_scale

Open jakehoare opened this issue 6 years ago • 4 comments

I am attempting to set_continuous_color_scale on a treemap with the code below and it produces the error visible should be a boolean

df = data.frame(Count = c(10,20,30,40),
                L1 = c("A", "A", "B", "B"),
                L2 = c("C1", "C2", "D1", "D2"),
                stringsAsFactors = FALSE)

D3partitionR() %>%
    add_data(df, count = "Count", steps = c("L1","L2"), color = "Count") %>%
    set_chart_type('treemap') %>%
    set_continuous_color_scale(c("#aabbcc", "#112233")) %>%
    plot()

I have made various attempts to set visible with set_labels_parameters, set_legend_parameters, set_tooltip_parameters and set_trail that have failed to resolve the issue.

How do I use this function (or any other method) to modify the colors? Thanks

jakehoare avatar Apr 27 '18 02:04 jakehoare

You're right, there is a bug in there. I will look into it.

AntoineGuillot2 avatar Jun 02 '18 15:06 AntoineGuillot2

This should be corrected in the dev branch.

AntoineGuillot2 avatar Jun 02 '18 15:06 AntoineGuillot2

Hi, looks like the issue is occurring again. Is there anyway around this issue?

acobb83 avatar Dec 13 '19 03:12 acobb83

Hi @acobb83, are you using the github version or the cran one ?

AntoineGuillot2 avatar Dec 19 '19 14:12 AntoineGuillot2