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

This manual palette can handle a maximum of 10 values. You have supplied 12 #175

Open
arroe99 opened this issue Aug 4, 2024 · 1 comment

Comments

@arroe99
Copy link

arroe99 commented Aug 4, 2024

微信图片_20240804114949

library(readxl)
df = read_excel("testcode.xls", sheet = 1, na = "NA")

long_df <- df %>%

  • pivot_longer(cols = everything(), names_to = "Region", values_to = "Value")

table(long_df$Region)

Central [NNS] Central [NS] Frontal [NNS] Frontal [NS]
200 200 200 200
Overall[NNS] Overall[NS] Parietal [NNS] Parietal [NS]
200 200 200 200
Prefrontal [NNS] Prefrontal [NS] Temporal [NNS] Temporal [NS]
200 200 200 200

idx <- list(

  • c("Overall[NS]", "Overall[NNS]"),
  • c("Prefrontal [NS]", "Prefrontal [NNS]"),
  • c("Frontal [NS]", "Frontal [NNS]"),
  • c("Temporal [NS]", "Temporal [NNS]"),
  • c("Central [NS]", "Central [NNS]"),
  • c("Parietal [NS]", "Parietal [NNS]")
  • )

dabest_obj <- long_df %>%

  • dabestr::load(x = Region, y = Value,
  •    idx = idx)
    

dabest_obj %>%

  • mean_diff() %>%
  • dabest_plot()
    Warning messages:
    1: This manual palette can handle a maximum of 10 values. You have supplied 12
    2: Removed 400 rows containing missing values or values outside the scale range
    (geom_point()).
    3: In get_plot_component(plot, "guide-box") :
    Multiple components found; returning the first one. To return all, use return_all = TRUE.
    4: This manual palette can handle a maximum of 10 values. You have supplied 12
    5: Removed 400 rows containing missing values or values outside the scale range
    (geom_point()).
    6: This manual palette can handle a maximum of 10 values. You have supplied 12
@arroe99 arroe99 closed this as not planned Won't fix, can't repro, duplicate, stale Aug 4, 2024
@arroe99 arroe99 reopened this Aug 4, 2024
@arroe99
Copy link
Author

arroe99 commented Aug 4, 2024

First of all, I'm sorry that my code format is a bit messy.
My problem is just as the title of this issue. My data has 12 columns, but when drawing the graph, it can only accept up to 10 categories, resulting in the last two categories being blank in the graph.
What should I do to solve this problem?

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

1 participant