Questions tagged [abline]

21 questions
0
votes
0 answers

Generating separate plots for each unique subject ID by adding abline() and lines()

I am trying to plot (a kind of) longitudinal observations by ID adding some more informations. I followed what it is stated here Generating separate plots for each unique subject ID and save them in the working directory with the subject ID…
0
votes
0 answers

Quantile Line is offset on Boxplot

I tried visualizing a boxplot and highlighting the 25% and 75% quantile using the abline function but it does not seem to align as expected. Does it look misaligned to you? For reference, I have included a summary of the data. I appreciate your…
Kimberly
  • 5
  • 2
0
votes
1 answer

How to push an abline grid to the background in a plot?

I'm trying to plot a grid for a time series plot using abline(). It works fine, but I'm not able to draw the grid lines in the background: they are above the time series line. I'm using the following code: options(repr.plot.width=15,…
AlejandroDGR
  • 178
  • 1
  • 10
0
votes
1 answer

How to make ggplot show the linetype and line colour in the legend?

How can I make the legend show not only the line colour, but also the linetype? I want the grey line next to "y = x" to be dashed, like in the plot. Here is the code I used to make the plot, with some sample data: # Sample data df_REM24_Q <-…
0
votes
0 answers

Abline error: requiring "names or character strings"

After creating a plot of plant height vs shoot diameter, I want to add a line resulting from a linear regression. However, I keep getting a strange error with abline(). plot(log(conyza$diameter_cm), log(conyza$height_cm), main = "Shoot diameter and…
Kat
  • 1
0
votes
1 answer

Error plotting lines on a graph made in R

Could you help me solve following issue: I have two codes that were made to generate the same scatter plot. The first one works normally, generates the graph and the lines without any problems. It is a code that requires vector i to generate the…
Antonio
  • 1,091
  • 7
  • 24
1
2