[R] Two gganimate questions.

2019-02-07 Thread Roy Mendelssohn - NOAA Federal via R-help
I have two gganimate questions that I have made some headway on but not too much, and they are actually related. The questions are: 1. Suppose I have a list where each element of the list is a pre-defined ggplots2 graphic (in my case each is a map). Is there a way to animate this, and if

Re: [R] very slow code execution

2019-02-07 Thread Bob O'Hara
With 96k model fits it's going to be slow, so you might want to think first about whether you need to do them all. Beyond that, I think this is more in the R style, so might be quicker (I don't know how much the loops are slowing you down), and even if not it should be easier to adapt. The other t

[R] using ggplot2 geom_path() in a grouped variable

2019-02-07 Thread Norberto Hernandez
Hi! I am trying to make a scatter/path graph in one variable that is divided in two groups (variable Control), but when I use the geom_path() option, the line continues from the group one to the group two, and I wasn't able to avoid it.I need the path draws over the group one and then draws over th

[R] Spacing around \cdot (%.%) unequal in pdf

2019-02-07 Thread Pascal A. Niklaus
I am struggling labeling an axis in a plot. Here is a minimal example illustrating the point: pdf("mve.pdf",width=5,height=5) ypos <- c(1:3) * 1e6 ylabs <- sapply(ypos/1e6, function(i) as.expression(bquote(.(i)%.%10^6))) plot(rep(1,3), ypos, yaxt="n", ylab="") axis(2, at=ypos, labels=ylabs, las

[R] [R-pkgs] Jim Lindsey's packages back on CRAN

2019-02-07 Thread Bruce Swihart
R Users, Jim Lindsey's R packages: * event: Event History Procedures and Models * gnlm: Generalized Nonlinear Regression Models * growth: Multivariate Normal and Elliptically-Contoured Repeated Measurements Models * repeated: Non-Normal Repeated Measurements Models * rmutil: Utilities f

Re: [R] Nearest neighbors of a of 3D points

2019-02-07 Thread Eric Leroy
I tried the spatstat package. In the meanwhile, I think that I found the solution: with the pp3 command, I was able to create a pp3 object that is recognized by nndist. I will give a look at the other packages you mentioned seeing what are the differences. Anyway, thank you for your answer.

Re: [R] very slow code execution

2019-02-07 Thread salah maadawy
Hi Micheal, Maybe there is a simple way but i wanted to get the lowest aicc ana i could not find a way to do so, that's why i created the table to store all possible outcomes and then i can easily get the minimum value and the values of (i,j and k) used for that minimum value. The first column in

Re: [R] very slow code execution

2019-02-07 Thread Michael Dewey
Well I do not know about data.table but in standard R if you go AICc[,1] <- 3 it fills the whole column with 3 so you will end up with a table with the last value of AICc stored in every row which is almost certainly not what you want. Michael On 06/02/2019 14:15, salah maadawy wrote: Hi Mich