- using R version 2.13.0 Under development (unstable) (2011-02-22 r54548)
- using platform: i386-apple-darwin9.8.0 (32-bit)
- using session charset: UTF-8
- checking for file ‘mixAK/DESCRIPTION’ ... OK
- this is package ‘mixAK’ version ‘1.3’
- package encoding: UTF-8
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking for executable files ... OK
- checking whether package ‘mixAK’ can be installed ... OK
- checking installed package size ... NOTE
installed size is 20.5Mb
sub-directories of 1Mb or more:
data 3.4Mb
doc 11.4Mb
libs 5.1Mb
- checking package directory ... OK
- checking for portable file names ... OK
- checking for sufficient/correct file permissions ... OK
- checking DESCRIPTION meta-information ... OK
- checking top-level files ... OK
- checking index information ... OK
- checking package subdirectories ... OK
- checking R files for non-ASCII characters ... OK
- checking R files for syntax errors ... OK
- loading checks for arch ‘i386’
** checking whether the package can be loaded ... OK
** checking whether the package can be loaded with stated dependencies ... OK
** checking whether the package can be unloaded cleanly ... OK
- loading checks for arch ‘ppc’
** checking whether the package can be loaded ... OK
** checking whether the package can be loaded with stated dependencies ... OK
** checking whether the package can be unloaded cleanly ... OK
- loading checks for arch ‘x86_64’
** checking whether the package can be loaded ... OK
** checking whether the package can be loaded with stated dependencies ... OK
** checking whether the package can be unloaded cleanly ... OK
- checking for unstated dependencies in R code ... OK
- checking S3 generic/method consistency ... OK
- checking replacement functions ... OK
- checking foreign function calls ... OK
- checking R code for possible problems ... OK
- checking Rd files ... OK
- checking Rd metadata ... OK
- checking Rd cross-references ... OK
- checking for missing documentation entries ... OK
- checking for code/documentation mismatches ... OK
- checking Rd \usage sections ... OK
- checking Rd contents ... OK
- checking for unstated dependencies in examples ... OK
- checking contents of 'data' directory ... OK
- checking data for non-ASCII characters ... OK
- checking data for ASCII and uncompressed saves ... OK
- checking line endings in C/C++/Fortran sources/headers ... OK
- checking line endings in Makefiles ... OK
- checking for portable compilation flags in Makevars ... OK
- checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
- checking sizes of PDF files under inst/doc ... OK
- checking examples ...
** running examples for arch ‘i386’ ... OK
** running examples for arch ‘ppc’ ... ERROR
Running examples in ‘mixAK-Ex.R’ failed
The error most likely occurred in:
> ### Name: MVNmixture
> ### Title: Mixture of (multivariate) normal distributions
> ### Aliases: MVNmixture dMVNmixture dMVNmixture2 rMVNmixture rMVNmixture2
> ### Keywords: distribution multivariate
>
> ### ** Examples
>
> set.seed(1977)
>
> ##### Univariate normal mixture
> ##### =========================
> mu <- c(-1, 1)
> Sigma <- c(0.25^2, 0.4^2)
> Q <- 1/Sigma
> w <- c(0.3, 0.7)
>
> xx <- seq(-2, 2.5, length=100)
> yyA <- dMVNmixture(xx, weight=w, mean=mu, Sigma=Sigma)
> yyB <- dMVNmixture(xx, weight=w, mean=mu, Q=Q)
> yyC <- dMVNmixture2(xx, weight=w, mean=mu, Sigma=Sigma)
> yyD <- dMVNmixture2(xx, weight=w, mean=mu, Q=Q)
>
> xxSample <- rMVNmixture(1000, weight=w, mean=mu, Sigma=Sigma)
> xxSample2 <- rMVNmixture2(1000, weight=w, mean=mu, Sigma=Sigma)
>
> sum(abs(xxSample2$dens - dMVNmixture(xxSample2$x, weight=w, mean=mu, Sigma=Sigma)) > 1e-15)
[1] 0
> xxSample2 <- xxSample2$x
>
> par(mfrow=c(2, 2), bty="n")
> plot(xx, yyA, type="l", col="red", xlab="x", ylab="f(x)")
> points(xx, yyB, col="darkblue")
> hist(xxSample, col="lightblue", prob=TRUE, xlab="x", xlim=range(xx), ylim=c(0, max(yyA)), main="Sampled values")
> lines(xx, yyA, col="red")
> plot(xx, yyC, type="l", col="red", xlab="x", ylab="f(x)")
> points(xx, yyD, col="darkblue")
> hist(xxSample2, col="sandybrown", prob=TRUE, xlab="x", xlim=range(xx), ylim=c(0, max(yyA)), main="Sampled values")
> lines(xx, yyC, col="red")
>
>
> ##### Bivariate normal mixture
> ##### ========================
> ### Choice 1
> sd11 <- sd12 <- 1.1
> sd21 <- 0.5
> sd22 <- 1.5
> rho2 <- 0.7
> Xlim <- c(-3, 4)
> Ylim <- c(-6, 4)
>
> ### Choice 2
> sd11 <- sd12 <- 0.3
> sd21 <- 0.5
> sd22 <- 0.3
> rho2 <- 0.8
> Xlim <- c(-3, 2.5)
> Ylim <- c(-2.5, 2.5)
>
> mu <- matrix(c(1,1, -1,-1), nrow=2, byrow=TRUE)
> Sigma <- list(diag(c(sd11^2, sd12^2)), matrix(c(sd21^2, rho2*sd21*sd22, rho2*sd21*sd22, sd22^2), nrow=2))
> Q <- list(chol2inv(chol(Sigma[[1]])), chol2inv(chol(Sigma[[2]])))
> w <- c(0.3, 0.7)
>
> xx1 <- seq(mu[2,1]-3*sd21, mu[1,1]+3*sd11, length=100)
> xx2 <- seq(mu[2,2]-3*sd22, mu[1,2]+3*sd12, length=90)
> XX <- cbind(rep(xx1, length(xx2)), rep(xx2, each=length(xx1)))
> yyA <- matrix(dMVNmixture(XX, weight=w, mean=mu, Sigma=Sigma), nrow=length(xx1), ncol=length(xx2))
> yyB <- matrix(dMVNmixture(XX, weight=w, mean=mu, Q=Q), nrow=length(xx1), ncol=length(xx2))
> yyC <- matrix(dMVNmixture2(XX, weight=w, mean=mu, Sigma=Sigma), nrow=length(xx1), ncol=length(xx2))
> yyD <- matrix(dMVNmixture2(XX, weight=w, mean=mu, Q=Q), nrow=length(xx1), ncol=length(xx2))
>
> xxSample <- rMVNmixture(1000, weight=w, mean=mu, Sigma=Sigma)
*** caught segfault ***
- elapsed time (check, wall clock): 204:53