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

Combine ggupset with geom_raster #40

Open
Alexandr3K3vin opened this issue Sep 18, 2023 · 0 comments
Open

Combine ggupset with geom_raster #40

Alexandr3K3vin opened this issue Sep 18, 2023 · 0 comments

Comments

@Alexandr3K3vin
Copy link

Hy,

I want to combine ggupset x axis with a plot run by geom_raster()
But geom_raster only works with coord_cartesian

here is the error message :

Error in geom_raster():
! Problem while converting geom to grob.
ℹ Error occurred in the 1st layer.
Caused by error in draw_panel():
! geom_raster() only works with coord_cartesian()
Run rlang::last_trace() to see where the error occurred.

my code is :
db_mic.t6%>%
filter(ATB=="CIP")%>%
ggplot(aes(x=KroR_list, y=P_R))+
geom_raster(aes(fill=MIC))+
scale_x_upset()

and my data base description

A tibble: 81 × 3

KroR_list MIC P_R

1 0.004 WT
2 0.004 WT
3 <chr [1]> 0.015 WT
4 <chr [1]> 0.06 WT
5 <chr [2]> 0.125 WT
6 <chr [2]> 0.25 WT
7 <chr [3]> 0.5 WT
8 <chr [2]> 0.06 WT
9 <chr [3]> 0.125 WT
10 <chr [3]> 1 WT

ℹ 71 more rows

ℹ Use print(n = ...) to see more rows

Do someone know to resolve this issue please ?

Many thanks

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