Skip to main content

All Questions

Tagged with
0 votes
0 answers
27 views

Duplicated points in ggplot2 animation [closed]

I'm trying to do a visualization which is animated. Problem: my points show duplicated regardless that I put the transition_time parameter to show the points every year. Inside aes function I also ...
Juan Carlos Saravia's user avatar
0 votes
1 answer
26 views

Error in bi_class() function: the condition has length > 1 while using Shiny

I am building an RShiny dashboard that allows the user to select two variables which then is plotted onto a bivariate map. This is the code so far: library(ggplot2) library(ggspatial) library(cowplot) ...
ElisJD's user avatar
  • 1
0 votes
0 answers
18 views

How to define specific colors for Errorbars in R using ggplot? [duplicate]

I want to generate a plot (copies vs. measurement) with data from two machines (A and B). For each machine, I calculated a linear model to display a regression line as well as the datapoints and the ...
Piratepenguin's user avatar
0 votes
0 answers
29 views

how to get a list of adjusted p values from ggplot code [closed]

I am a beginner in rstudio and interested to obtain the adjusted p values and save it as .csv file for a set of manually selected genes from single cell RNA seq data using the below code. tumor.plot = ...
SSIL's user avatar
  • 1
2 votes
1 answer
26 views

Remove gap in line plot in R [duplicate]

Please help me plot a single line that changes from solid (measured) to dashed (estimate) after year 2008 and has a legend respectively. My code: date<-as.POSIXct(c("1981-01-01","...
DAY's user avatar
  • 111
0 votes
1 answer
21 views

How to plot two separate pairs of points and connect them using ggplot?

I would like to plot two separate pairs of points on a ggplot and then connect them by a line. I know I could create two ggplots and then combine them together, but then no line would be connecting ...
Loons22's user avatar
  • 373
1 vote
1 answer
32 views

ggplot are all the same when yaml parameter is passed and quarto_render is used in loop

I want to render multiple html documents using quarto_render I have a main.qmd containing: library(quarto) library(glue) # List of IDs of interest ids <- c("A", "B", "C&...
Kuehlschrank's user avatar
0 votes
0 answers
27 views

How to add count labels to clustered stacked bar chart in ggplot? (R) [closed]

I have a bar chart that looks like this: I am happy with how it looks except that I am trying to add labels to my bars showing the count of each bar. ##Current Code library(ggplot2) typeXsize <- ...
sionnach's user avatar
0 votes
1 answer
36 views

Failing to automate slide creation for each plot (pptx format, R)

I have a list with 100 plots which I want to automate via quarto such that each plot is produced in a new slide of a power point presentation. I am using Quarto 1.4.555 with R 4.4.0 via RStudio 2024.4....
Yann's user avatar
  • 55
1 vote
2 answers
30 views

Legend fails to show a category in ggplot when this category only has partial values

I have a reproducible code that generates three independent datasets and a combined dataset mydata. The dataset3 have less values, especially missing some values for certain n categories. mydata1 <-...
Phoebe's user avatar
  • 103
0 votes
0 answers
37 views

Why is my Shiny app not generating a plot?

I am attempting to generate a plot using variables in my server code that can be changed- I'm not sure if I am formatting this wrong and that is why a plot is not generating. My goal is to generate a ...
DN98024's user avatar
  • 11
-1 votes
0 answers
21 views

Create a layered ggplot with 2 different scale x axis? [duplicate]

I'm a litte stuck, I wanna create a plot showing 2 variables based on time, however one of those variable needs to be shown on a log scale (going from 0.01 to 100), and the other one on a regular ...
IlyLemon's user avatar
4 votes
0 answers
50 views

When extending ggplot2, how should I apply scaling functions per group instead of as a whole?

I'm working on a new geom for ggplot2 that allows the user to alter the tint and shade of the colors by mapping it to an aesthetic. (If someone knows of a place this has already been implemented, ...
Dubukay's user avatar
  • 2,123
0 votes
0 answers
27 views

How to Improve Kernel Density Estimation Plot Map Grid Cells for Vessel Traffic on the West Coast of Mexico in R?

I'm working on visualizing vessel traffic density for the west coast of Mexico, including Baja California and Bahia de Banderas waters, using R. I have a large dataset of vessel locations stored in a ...
Charlene Perez Santos's user avatar
0 votes
1 answer
41 views

ggrepel how to force geom_text_repel to draw a label line between the text label and its respective point?

> dput(d) structure(list(line = structure(c(4L, 4L, 4L, 4L, 4L, 5L, 5L, 5L, 5L, 5L, 5L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 7L, 7L, 7L, 7L, 7L, 7L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 9L, 9L, 9L, 9L, ...
Ishan Mehta's user avatar

15 30 50 per page
1
2 3 4 5
3732