I want to be able to add a new line/trace to a plotly object. This plotly object will be created from a ggplot object using ggplotly. I tried 1. creating the pl
Hello and thank you for you time and consideration, I'd like to recreate this graph with ggplot. The top blue dots are the predicted values from my fitted model
I'm trying to plot a Sankey diagram of financial flows between a source country and counterpart country. ggplot(dat_ggforce, aes(x=x, id=id, split = y, value=yv
I want to add a unique horizontal line across each row of a set of facet grid boxplots. x<-c("species_X","species_X","species_X", "species_Y","species_Y",
I am trying to plot a multi-panel Lollipop chart using ggplot2 using the following code #Data df =structure(list(Indices = c("Time", "Z11", "Z51", "Z61", "Z161"
Im trying to figure out the best way to plot changes in water potential through summer comparing two factors, soil cover treatments and irrigation. I reached a
I have this dataframe. I create a plot representing on the y-axis "value" and on the x-axis each of the levels of "Column_S", which contains levels from S1 to S
I have been trying to amend what I thought was a straightforward legend on my GGPlot for a day now and not making much progress (I have searched extensively on
I just need to write some code that will look at the difference between the "est_age" and "known_age" columns in my data set. Then I need to know what percenta
I have a dataset with two groups - Experimental and Control. Each participant contributes two responses per group, which represent different learning styles. Th
Example data are here I am struggling to create an ordered and grouped bar plot. Any assistance appreciated. I have found two similar questions that essentially
I would like to arrange multiple plots into one figure, without any gaps between the plot area, and all plots being exactly the same size (see image below for a
With untidy data, running a scatterplot comparing two variables is trivial in either base R or ggplot2. For example, here is a sample scatterplot from R for Dat
i want to create a combination of violin- and dot-plot with ggplot. The idea is to shift the dots to the left and right if necessary, to avoid overlap. I know t
The image shows the database, it starts with day 0 and ends with day 14. In between these, there are empty values for what I am plotting. I am unable to correc
I have a ggplot which looks like this. p2=ggplot(data=data1, aes(x=ID, y = value)) + geom_line(group=1,color='steelblue', size=2) + facet_wrap(~variable)+t
I would like to create a ggplot2 bar chart with round corners at the top of the bars. Consider the following example data: data <- data.frame(x = letters[1:
I am wondering about the "behind-the-scenes functionality of ggplot2 and cut_number. I have some pretty complex data that has many subsets of data with a relati
library(tidyverse) library(ggplot2) library(plotly) data(mpg) ggplotly( mpg %>% ggplot(aes(x=hwy)) + geom_histogram(), tooltip = ("all")) When you
I'm trying to get 300 dpi images with ggsave, and am only getting the default 72 dpi. Here's an example of the code I'm using: library(tidyverse) x <- rnorm(