Questions tagged [position-dodge]

20 questions
0
votes
1 answer

Position stacked identity data sample size as geom_text directly over a bar using geom_bar from ggplot2

In this experiment, we tracked presence or absence of bacterial infection in our subject animals. We were able to isolate which type of bacteria was present in our animals and created a plot that has Week Since Experiment Start on the X axis, and…
ruser123
  • 35
  • 3
0
votes
1 answer

How to change the order of dodged columns in R?

I am trying to display dodged columns in descending order by the 'rank' variable, since they show up in ascending order, but I can't seem to figure that out. I have tried to adapt some suggestions already posted to no avail. When I try the…
pixel9
  • 5
  • 3
0
votes
1 answer

how to reorder bars in ggplot position_dodge2 barplot?

I have a dataset that I would love to be able to arrange the bars in it by descending order. I've used position_dodge2 to be able to look at the subsets within each category, but i want it to be by descending order of both 1. overall category…
salix7
  • 61
  • 5
0
votes
1 answer

Show alpha/opacity in ggplot legend

I have two dodge bar chart which I have put on top of each other to create this plot. Groups <- c(1, 2,1,2,1,2) variable <- c("Yes", "Yes", "Maybe", "Maybe", "No", "No") value <- c(50,60,70,80,90,100) df <- data.frame(Groups, variable,…
Alis
  • 80
  • 7
0
votes
1 answer

geom points are not placed on the boxplot?

I don't know how to align the dots to each belong to it is box plot. Why they are appearing like that? I found this post, but it is answering the dodging part which is not part of my code here is my…
1
2