R ggplot: Using geom_text or geom_label inside geom_bar
I am plotting the publication of scientific papers on a specific research topic on a timeline. I would like to add author and year to the corresponding rectangles using the “label” variable.
How to adjust position of geom_text() with counts of zero for bars of barplot with geom_bar() in different groups?
I’m trying to add values at the top of my bars of a barchart with two groups. It works fine for values above zero.
But I have also levels where there were no counts, so bars with the hight of 0. Then the text on top of the bar with counts is in the middle instead of right above the bar. And the place with count 0 has no indication.
How to swap labels on stacked bar graph using geom_text?
When producing a stacked bar graph that has different color by facet variable and bar fill variable, I would like to add the number/count by each color. I am using the geom_text function by it seems to be swapping the order of the numbers for each bar.