Closed Mariaf1714 closed 10 months ago
Hi @Mariaf1714
You can use two equivalent e_pie charts in one echart with different label positions.
Like this:
library(echarts4r)
df <- data.frame(name = c("this", "is", "an", "example"),
percentage = c(10, 20, 30, 40))
df |>
e_charts(name) %>%
e_pie(percentage,
label = list(formatter = "{c} %",
position = "inside")) |>
e_pie(percentage,
label = list(formatter = '{b}')) |>
e_legend(show = FALSE)
the result looks like this:
Is this the result you intended? If yes, please close the issue, thanks!
This is exactly the result that I intended. Thank you!!
The code works. Thank you very much.
Hallo, Is it possible to display a part of the label (for example
formatter = "{c} %"
) usingposition = "inside"
and another part of the label (formatter = '{b}'
) with theposition = "outside"
in a e_pie chart? The names in {b} should not be displayed in a legend.Thank you!