- using R Under development (unstable) (2012-02-23 r58468)
- using platform: i686-pc-linux-gnu (32-bit)
- using session charset: UTF-8
- checking for file ‘PSAgraphics/DESCRIPTION’ ... OK
- this is package ‘PSAgraphics’ version ‘2.01’
- checking package namespace information ... OK
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking if there is a namespace ... OK
- checking for executable files ... OK
- checking whether package ‘PSAgraphics’ can be installed ... OK
- checking installed package size ... OK
- 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
- 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 whether the namespace can be loaded with stated dependencies ... OK
- checking whether the namespace 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 ... WARNING
‘library’ or ‘require’ call not declared from: ‘rpart’
- checking contents of ‘data’ directory ... OK
- checking data for non-ASCII characters ... OK
- checking data for ASCII and uncompressed saves ... OK
- checking examples ... ERROR
Running examples in ‘PSAgraphics-Ex.R’ failed
The error most likely occurred in:
> ### Name: cat.psa
> ### Title: Compare balance graphically of a categorical covariate as part
> ### of a PSA
> ### Aliases: cat.psa
> ### Keywords: hplot htest
>
> ### ** Examples
>
> categorical<-sample(1:7,1000,replace=TRUE)
> treatment<-sample(c(0,1),1000,replace=TRUE)
> strata<-sample(5,1000,replace=TRUE)
> cat.psa(categorical,treatment,strata)
$`treatment:stratum.proportions`
0:1 1:1 0:2 1:2 0:3 1:3 0:4 1:4 0:5 1:5
1 0.136 0.119 0.102 0.18 0.133 0.139 0.121 0.173 0.154 0.133
2 0.126 0.110 0.176 0.16 0.200 0.168 0.131 0.074 0.135 0.156
3 0.126 0.128 0.167 0.13 0.162 0.178 0.131 0.148 0.192 0.133
4 0.126 0.138 0.157 0.17 0.124 0.149 0.141 0.136 0.154 0.211
5 0.126 0.138 0.111 0.12 0.143 0.139 0.162 0.123 0.087 0.122
6 0.184 0.202 0.130 0.13 0.114 0.149 0.101 0.173 0.125 0.111
7 0.175 0.165 0.157 0.11 0.124 0.079 0.212 0.173 0.154 0.133
>
> data(lindner)
> attach(lindner)
> lindner.ps <- glm(abcix ~ stent + height + female +
+ diabetic + acutemi + ejecfrac + ves1proc,
+ data = lindner, family = binomial)
> ps<-lindner.ps$fitted
> lindner.s5 <- as.numeric(cut(ps, quantile(ps, seq(0, 1, 1/5)),
+ include.lowest = TRUE, labels = FALSE))
> cat.psa(stent, abcix, lindner.s5, xlab = "stent")
$`treatment:stratum.proportions`
0:1 1:1 0:2 1:2 0:3 1:3 0:4 1:4 0:5 1:5
0 0.853 0.771 0.253 0.226 0.138 0.163 0.233 0.269 0.25 0.185
1 0.147 0.229 0.747 0.774 0.862 0.837 0.767 0.731 0.75 0.815
>
> lindner.s10 <- as.numeric(cut(ps, quantile(ps, seq(0, 1, 1/10)),
+ include.lowest = TRUE, labels = FALSE))
> cat.psa(ves1proc,abcix, lindner.s10, balance = TRUE, xlab = "ves1proc")
Histogram of Random Strata Balance. Press <enter> for next chart...
$`treatment:stratum.proportions`
0:1 1:1 0:2 1:2 0:3 1:3 0:4 1:4 0:5 1:5 0:6 1:6 0:7
0 0.017 0.071 0.000 0 0.000 0.000 0 0.000 0.000 0.000 0.000 0.000 0.000
1 0.983 0.929 0.946 1 0.857 0.969 1 0.917 0.897 0.814 0.889 0.815 0.583
2 0.000 0.000 0.054 0 0.143 0.031 0 0.083 0.103 0.186 0.111 0.185 0.375
3 0.000 0.000 0.000 0 0.000 0.000 0 0.000 0.000 0.000 0.000 0.000 0.042
4 0.000 0.000 0.000 0 0.000 0.000 0 0.000 0.000 0.000 0.000 0.000 0.000
5 0.000 0.000 0.000 0 0.000 0.000 0 0.000 0.000 0.000 0.000 0.000 0.000
1:7 0:8 1:8 0:9 1:9 0:10 1:10
0 0.000 0.000 0.000 0.000 0.000 0.000 0.000
1 0.486 0.263 0.195 0.364 0.379 0.000 0.253
2 0.500 0.737 0.732 0.545 0.460 0.444 0.396
3 0.014 0.000 0.073 0.091 0.161 0.444 0.198
4 0.000 0.000 0.000 0.000 0.000 0.111 0.143
5 0.000 0.000 0.000 0.000 0.000 0.000 0.011
>
> #Using a rpart tree for strata
> library(rpart)
Error in library(rpart) : there is no package called ‘rpart’
Execution halted