[R] to R Core T: mle function in 32bits not respecting the constrain

2018-05-27 Thread francesc badia roca
I have an issue using mle in versions of 32 bits. I am writing a package which I want to submit to the CRAN. When doing the check, there is an example that has an error running in the 32 bits version. The problem comes from the mle function, using it with a lower constrain. In 64 bits version it

Re: [R] if else with 4 conditions problem

2018-05-27 Thread Rui Barradas
Hello, It's just a sequence of ifelse instructions. dat <- read.table(text = " A B 1 1 1 0 0 1 0 0 ", header = TRUE) dat$A1 <- ifelse(dat$A == 1 & dat$B == 1, 1, 0) dat$A2 <- ifelse(dat$A == 1 & dat$B == 0, 1,

[R] if else with 4 conditions problem

2018-05-27 Thread smart hendsome via R-help
Hi everyone, I have two columns:    A               B    1               1   1               0    0               1    0               0 I have 4 categories which are: 1) if A = 1 and B =1 then A1 = 1, else A2 = 0, A3 = 0, A4 = 0 2) if A = 1 and B =0 then A1 = 0, else A2 =1, A3 = 0, A4 = 0 3) if

Re: [R] update.packages() after updating R version [RESOLVED]

2018-05-27 Thread Rich Shepard
On Sat, 26 May 2018, Duncan Murdoch wrote: I think you want update.packages(ask = FALSE, checkBuilt = TRUE) to automatically update all packages and their dependencies. With the default checkBuilt=FALSE, R just sees whether a dependency is a high enough version number. But packages installed und

Re: [R] legend order in ggplot2

2018-05-27 Thread Tom Hopper
John, The order of legends in ggplot2 depends on the order of factor levels in the data frame. The linetype can be matched to the factor levels using a named vector (ggplot2 basically does a lookup). The biggest problem you have here is that you’re not passing data in the right form or format