I converted to factor because, in barchart, x-axis seems to be factor only.
Without factor, x labels are 1, 2, 3, …
Solution 1 works for me. If there is a method for barchart, I am interested in
looking at that as well.
Thanks,
Naresh
Sent from my iPhone
> On Nov 18, 2023, at 10:09 AM, Deepa
On Sat, 18 Nov 2023 at 06:44, Naresh Gurbuxani
wrote:
>
> In below graph, I would like to add two vertical lines using
> panel.abline(). Is this possible?
I assume you want the 'v' variable in panel.abline() to be interpreted
in the context of your x-axis, which here represents a factor
variable
In below graph, I would like to add two vertical lines using
panel.abline(). Is this possible?
Thanks,
Naresh
mydf <- data.frame(hour = rep(6:20, 2),
traffic = c(round(dnorm(6:20, 9, 3) * 1), round(dnorm(6:20, 17, 4) *
1)),
direction = rep(c("inbound", "outbound"), c(15, 15)))
vehicles
3 matches
Mail list logo