Last data update: 2014.03.03

R: Print a RE-EM Tree object
printR Documentation

Print a RE-EM Tree object

Description

This function prints a description of a fitted RE-EM tree object.

Usage

print.REEMtree(x,...)

Arguments

x

fitted model of class REEMtree

...

further arguments passed to or from other methods

Details

This function is a method for the generic function print for class REEMtree. It can be invoked by calling print for an object of class REEMtree, or by calling print.REEMtree directly for an object of the corresponding type.

Side Effects

Prints representations of the regression tree and the random effects model that comprise a RE-EM tree.

Author(s)

Rebecca Sela rsela@stern.nyu.edu

References

Sela, Rebecca J., and Simonoff, Jeffrey S., “RE-EM Trees: A Data Mining Approach for Longitudinal and Clustered Data”, Machine Learning (2011).

See Also

print.rpart, REEMtree.object

Examples

data(simpleREEMdata)
REEMresult<-REEMtree(Y~D+t+X, data=simpleREEMdata, random=~1|ID)
print(REEMresult)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(REEMtree)
Loading required package: nlme
Loading required package: rpart
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/REEMtree/print.Rd_%03d_medium.png", width=480, height=480)
> ### Name: print
> ### Title: Print a RE-EM Tree object
> ### Aliases: print.REEMtree
> ### Keywords: print tree
> 
> ### ** Examples
> 
> data(simpleREEMdata)
> REEMresult<-REEMtree(Y~D+t+X, data=simpleREEMdata, random=~1|ID)
> print(REEMresult)
[1] "*** RE-EM Tree ***"
n= 600 

node), split, n, deviance, yval
      * denotes terminal node

1) root 600 1092.91700  1.3639420  
  2) D< 0.5 300  339.28840  0.5006719  
    4) X>=0.2503819 89   62.24319 -0.3697058 *
    5) X< 0.2503819 211  181.18360  0.8677981 *
  3) D>=0.5 300  306.48750  2.2272130  
    6) t< 5.5 125  111.18930  1.6862250 *
    7) t>=5.5 175  132.58370  2.6136330 *
[1] "Estimated covariance matrix of random effects:"
            (Intercept)
(Intercept)    3.660086
[1] "Estimated variance of errors: 0.887508271560221"
[1] "Log likelihood:  -914.122394149391"
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>