Re: [R] Can someone please have a look at this query on stackoverflow?

2023-11-18 Thread Olivier Crouzet
Indeed, it's not far from that. Actually stating these parameters (paperwidht and paperheight) with the geometry package replaces the A4 size (or any default size as e.g. letterpaper...) with specific dimensions. But the nuance is that common sizes are declared with, e.g. the 'paper=a4paper'

Re: [R] Can someone please have a look at this query on stackoverflow?

2023-11-18 Thread Ashim Kapoor
Dear Olivier, Many thanks. Best Regards, Ashim On Sat, Nov 18, 2023 at 2:36 PM Olivier Crouzet wrote: > > And indeed again (I did not understand your previous question exactly > at first), the 'hard-coded' definition of a landscape a4 sheet would > therefore be: > > paperwidth=29.7cm,

Re: [R] Can someone please have a look at this query on stackoverflow?

2023-11-18 Thread Olivier Crouzet
And indeed again (I did not understand your previous question exactly at first), the 'hard-coded' definition of a landscape a4 sheet would therefore be: paperwidth=29.7cm, paperheight=21cm Olivier. On Sat, 18 Nov 2023 13:20:49 +0530 Ashim Kapoor wrote: > Dear Olivier, > > Many thanks for

Re: [R] combine barchart and xyplot in lattice

2023-11-18 Thread Deepayan Sarkar
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

[R] combine barchart and xyplot in lattice

2023-11-18 Thread Naresh Gurbuxani
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

Re: [R] combine barchart and xyplot in lattice

2023-11-18 Thread Naresh Gurbuxani
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,