Re: [R] test if something was plotted on pdf device

2019-09-13 Thread PIKAL Petr
Dear Duncan Thank you for the code, I will test it or at least check what it does. I finally found probably easier solution. I stay with my original code if (dev.cur()==1) plot(ecdf(velik[,"ecd"]), main = ufil[j], col=i) else plot(ecdf(velik[,"ecd"]), add=T, col=i) After plot is finished and

Re: [R] test if something was plotted on pdf device

2019-09-12 Thread Duncan Murdoch
On 12/09/2019 7:10 a.m., PIKAL Petr wrote: Dear all Is there any simple way checking whether after calling pdf device something was plotted into it? In interactive session I used if (dev.cur()==1) plot(ecdf(rnorm(100))) else plot(ecdf(rnorm(100)), add=T, col=i) which enabled me to test if

[R] test if something was plotted on pdf device

2019-09-12 Thread PIKAL Petr
Dear all Is there any simple way checking whether after calling pdf device something was plotted into it? In interactive session I used if (dev.cur()==1) plot(ecdf(rnorm(100))) else plot(ecdf(rnorm(100)), add=T, col=i) which enabled me to test if plot is open But when I want to call eg.