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
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 withcoord_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 rowsDo someone know to resolve this issue please ?
Many thanks