We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The yticks.by argument of ggpar() only works without NAs. There is an easy fix for this, since the error message says
yticks.by
ggpar()
Error in seq.default(0, max(y), by = yticks.by) : 'to' must be a finite number
max(y) needs to be changed to max(y, na.rm = T) and the problem is solved.
max(y)
max(y, na.rm = T)
Here's a reproducable example
library(tidyverse) library(ggpubr) df1 <- tibble( sum1 = c(NA, round(runif(49, 0, 10), 0)), condition = rep(c("A", "B"), each = 25) ) a <- ggbarplot(df1, x = "condition", y = "sum1", add = "mean_se", ylim = c(0, 10)) ggpar(a, yticks.by = 2)
Unfortunatly I don't have much time at the moment. I will probably get to fix this and issue #71 in september, but until then just write
ggbarplot(na.omit(df1), x = "condition", y = "sum1", add = "mean_se", ylim = c(0, 10))
instead. Maybe someone else has time to fix it in the meantime.
The text was updated successfully, but these errors were encountered:
fix for #89: now, yticks.by works with NAs
84baca2
No branches or pull requests
The
yticks.by
argument ofggpar()
only works without NAs. There is an easy fix for this, since the error message saysmax(y)
needs to be changed tomax(y, na.rm = T)
and the problem is solved.Here's a reproducable example
Unfortunatly I don't have much time at the moment. I will probably get to fix this and issue #71 in september, but until then just write
instead. Maybe someone else has time to fix it in the meantime.
The text was updated successfully, but these errors were encountered: