Running examples in 'iRF-Ex.R' failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: na.roughfix
> ### Title: Rough Imputation of Missing Values
> ### Aliases: na.roughfix na.roughfix.default na.roughfix.data.frame
> ### Keywords: NA
> 
> ### ** Examples
> 
> data(iris)
> iris.na <- iris
> set.seed(111)
> ## artificially drop some data values.
> for (i in 1:4) iris.na[sample(150, sample(20)), i] <- NA
Error in sample.int(x, size, replace, prob) : invalid 'size' argument
Calls: [<- -> [<-.data.frame -> sample -> sample.int
Execution halted
Running examples in ‘iRF-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: na.roughfix
> ### Title: Rough Imputation of Missing Values
> ### Aliases: na.roughfix na.roughfix.default na.roughfix.data.frame
> ### Keywords: NA
> 
> ### ** Examples
> 
> data(iris)
> iris.na <- iris
> set.seed(111)
> ## artificially drop some data values.
> for (i in 1:4) iris.na[sample(150, sample(20)), i] <- NA
Error in sample.int(x, size, replace, prob) : invalid 'size' argument
Calls: [<- -> [<-.data.frame -> sample -> sample.int
Execution halted
Running examples in ‘iRF-Ex.R’ failed
The error most likely occurred in:

> ### Name: na.roughfix
> ### Title: Rough Imputation of Missing Values
> ### Aliases: na.roughfix na.roughfix.default na.roughfix.data.frame
> ### Keywords: NA
> 
> ### ** Examples
> 
> data(iris)
> iris.na <- iris
> set.seed(111)
> ## artificially drop some data values.
> for (i in 1:4) iris.na[sample(150, sample(20)), i] <- NA
Error in sample.int(x, size, replace, prob) : invalid 'size' argument
Calls: [<- -> [<-.data.frame -> sample -> sample.int
Execution halted
Running examples in ‘iRF-Ex.R’ failed
The error most likely occurred in:

> ### Name: na.roughfix
> ### Title: Rough Imputation of Missing Values
> ### Aliases: na.roughfix na.roughfix.default na.roughfix.data.frame
> ### Keywords: NA
> 
> ### ** Examples
> 
> data(iris)
> iris.na <- iris
> set.seed(111)
> ## artificially drop some data values.
> for (i in 1:4) iris.na[sample(150, sample(20)), i] <- NA
Error in sample.int(x, size, replace, prob) : invalid 'size' argument
Calls: [<- -> [<-.data.frame -> sample -> sample.int
Execution halted
Running examples in 'iRF-Ex.R' failed
The error most likely occurred in:

> ### Name: na.roughfix
> ### Title: Rough Imputation of Missing Values
> ### Aliases: na.roughfix na.roughfix.default na.roughfix.data.frame
> ### Keywords: NA
> 
> ### ** Examples
> 
> data(iris)
> iris.na <- iris
> set.seed(111)
> ## artificially drop some data values.
> for (i in 1:4) iris.na[sample(150, sample(20)), i] <- NA
Error in sample.int(x, size, replace, prob) : invalid 'size' argument
Calls: [<- -> [<-.data.frame -> sample -> sample.int
Execution halted
Running examples in 'iRF-Ex.R' failed
The error most likely occurred in:

> ### Name: na.roughfix
> ### Title: Rough Imputation of Missing Values
> ### Aliases: na.roughfix na.roughfix.default na.roughfix.data.frame
> ### Keywords: NA
> 
> ### ** Examples
> 
> data(iris)
> iris.na <- iris
> set.seed(111)
> ## artificially drop some data values.
> for (i in 1:4) iris.na[sample(150, sample(20)), i] <- NA
Error in sample.int(x, size, replace, prob) : invalid 'size' argument
Calls: [<- -> [<-.data.frame -> sample -> sample.int
Execution halted
Running examples in 'iRF-Ex.R' failed
The error most likely occurred in:

> ### Name: readForest
> ### Title: Pass data through a fitted forest, record node characteristics
> ###   [works for binary classification with continuous variables]
> ### Aliases: readForest
> 
> ### ** Examples
> 
>   n = 50; p = 10
>   X = array(rnorm(n*p), c(n, p))
>   Y = (X[,1]>0.35 & X[,2]>0.35)|(X[,5]>0.35 & X[,7]>0.35)
>   Y = as.factor(as.numeric(Y>0))
> 
>   train.id = 1:(n/2)
>   test.id = setdiff(1:n, train.id)
>   
>   rf <- randomForest(x=X, y=Y, keep.forest=TRUE, track.nodes=TRUE,
+     ntree=100)
>   rforest <- readForest(rfobj=rf, x=X, n.core=2)
>   head(rforest$tree_info)
NULL
> 
>  # count number of leaf nodes with at least 5 observations
>   sum(rforest$tree.info$size.node > 5)
[1] 284
> 
> 
> 
> 
> cleanEx()
Error: connections left open:
	<-CRANwin.fb05.statistik.uni-dortmund.de:11371 (sockconn)
	<-CRANwin.fb05.statistik.uni-dortmund.de:11371 (sockconn)
Execution halted
Running examples in 'iRF-Ex.R' failed
The error most likely occurred in:

> ### Name: readForest
> ### Title: Pass data through a fitted forest, record node characteristics
> ###   [works for binary classification with continuous variables]
> ### Aliases: readForest
> 
> ### ** Examples
> 
>   n = 50; p = 10
>   X = array(rnorm(n*p), c(n, p))
>   Y = (X[,1]>0.35 & X[,2]>0.35)|(X[,5]>0.35 & X[,7]>0.35)
>   Y = as.factor(as.numeric(Y>0))
> 
>   train.id = 1:(n/2)
>   test.id = setdiff(1:n, train.id)
>   
>   rf <- randomForest(x=X, y=Y, keep.forest=TRUE, track.nodes=TRUE,
+     ntree=100)
>   rforest <- readForest(rfobj=rf, x=X, n.core=2)
>   head(rforest$tree_info)
NULL
> 
>  # count number of leaf nodes with at least 5 observations
>   sum(rforest$tree.info$size.node > 5)
[1] 284
> 
> 
> 
> 
> cleanEx()
Error: connections left open:
	<-CRANwin.fb05.statistik.uni-dortmund.de:11751 (sockconn)
	<-CRANwin.fb05.statistik.uni-dortmund.de:11751 (sockconn)
Execution halted
Running examples in 'iRF-Ex.R' failed
The error most likely occurred in:

> ### Name: readForest
> ### Title: Pass data through a fitted forest, record node characteristics
> ###   [works for binary classification with continuous variables]
> ### Aliases: readForest
> 
> ### ** Examples
> 
>   n = 50; p = 10
>   X = array(rnorm(n*p), c(n, p))
>   Y = (X[,1]>0.35 & X[,2]>0.35)|(X[,5]>0.35 & X[,7]>0.35)
>   Y = as.factor(as.numeric(Y>0))
> 
>   train.id = 1:(n/2)
>   test.id = setdiff(1:n, train.id)
>   
>   rf <- randomForest(x=X, y=Y, keep.forest=TRUE, track.nodes=TRUE,
+     ntree=100)
>   rforest <- readForest(rfobj=rf, x=X, n.core=2)
>   head(rforest$tree_info)
NULL
> 
>  # count number of leaf nodes with at least 5 observations
>   sum(rforest$tree.info$size.node > 5)
[1] 284
> 
> 
> 
> 
> cleanEx()
Error: connections left open:
	<-CRANwin.fb05.statistik.uni-dortmund.de:11267 (sockconn)
	<-CRANwin.fb05.statistik.uni-dortmund.de:11267 (sockconn)
Execution halted
Running examples in 'iRF-Ex.R' failed
The error most likely occurred in:

> ### Name: readForest
> ### Title: Pass data through a fitted forest, record node characteristics
> ###   [works for binary classification with continuous variables]
> ### Aliases: readForest
> 
> ### ** Examples
> 
>   n = 50; p = 10
>   X = array(rnorm(n*p), c(n, p))
>   Y = (X[,1]>0.35 & X[,2]>0.35)|(X[,5]>0.35 & X[,7]>0.35)
>   Y = as.factor(as.numeric(Y>0))
> 
>   train.id = 1:(n/2)
>   test.id = setdiff(1:n, train.id)
>   
>   rf <- randomForest(x=X, y=Y, keep.forest=TRUE, track.nodes=TRUE,
+     ntree=100)
>   rforest <- readForest(rfobj=rf, x=X, n.core=2)
>   head(rforest$tree_info)
NULL
> 
>  # count number of leaf nodes with at least 5 observations
>   sum(rforest$tree.info$size.node > 5)
[1] 284
> 
> 
> 
> 
> cleanEx()
Error: connections left open:
	<-CRANwin.fb05.statistik.uni-dortmund.de:11621 (sockconn)
	<-CRANwin.fb05.statistik.uni-dortmund.de:11621 (sockconn)
Execution halted