Re: [R] Plot a line using ggplot2

2022-12-08 Thread Ebert,Timothy Aaron
Of Sorkin, John Sent: Thursday, December 8, 2022 8:06 PM To: r-help@r-project.org (r-help@r-project.org) Subject: [R] Plot a line using ggplot2 [External Email] Colleagues, I am trying to plot a simple line using ggplot2. I get the axes, but I don't get the line. Please let me know what

Re: [R] Plot a line using ggplot2

2022-12-08 Thread Jeff Newmiller
Please run your code before you send it. Your example is not reproducible. library(ggplot2) linedata<- data.frame( PointEstx = c( 1, 2 ) , PointEsty = c( 1, 1.5 ) ) # make sure we have a data frame str(linedata) #plot the data ggplot( linedata , aes( x = PointEstx , y = PointEsty )

[R] Plot a line using ggplot2

2022-12-08 Thread Sorkin, John
Colleagues, I am trying to plot a simple line using ggplot2. I get the axes, but I don't get the line. Please let me know what my error I am making. Thank you, John # Define x and y values PointEstx <- Estx+1.96*SE PointEsty <- 1 row2 <- cbind(PointEstx,PointEsty) linedata<- data_frame(rbind(r