Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customize the label #6

Open
orange-3711 opened this issue May 15, 2023 · 5 comments
Open

Customize the label #6

orange-3711 opened this issue May 15, 2023 · 5 comments

Comments

@orange-3711
Copy link

Hi @showteeth
I wanna customize my labels, not 'count' or 'freq'. How can I do it?
Thanks!!

@showteeth
Copy link
Owner

Hi,

library(ggpie)
library(ggplot2)

# use labs or guides
ggpie(data = diamonds, group_key = "cut", count_type = "full",
      label_info = c("count", "ratio"), label_type = "horizon", label_split = NULL,
      label_size = 4, label_pos = "in") + 
  # labs(fill = "MY NEW TITLE")
  guides(fill=guide_legend(title='MY NEW TITLE'))

@orange-3711
Copy link
Author

Thank you for your answer, I found the answer in other questions #4 (comment), but now I have another problem. My labels overlap because of too many words, is there any way to solve it?

image

@showteeth
Copy link
Owner

Why not try rose pie plot?

@orange-3711
Copy link
Author

orange-3711 commented May 15, 2023

Why not try rose pie plot?

That's a good choice. But I just want to label info as group.

image

@showteeth
Copy link
Owner

You can only choose label info from count, ratio, and all (count and ratio).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants