Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Library: xclust
See also: cartdrawpdfregr

Quantlet: cartdrawpdfclass
Description: generates TEX classification tree (to the file)

Reference(s):

Link:
Usage: cartdrawpdfclass(VarMatrix,ClassVector,SplitRule,MinSize, FilePath)
Input:
VarMatrix n x m matrix, variables
ClassVector n x 1 vector, classes
SplitRule scalar, splitting rule either 0 (Ginni) or 1 (Twoing)
MinSize scalar, stop condition, minimum number of observations in terminal node
FilePath Complete path to the file, including the name of the file, e.g. c:\tree.tex

Example:
library("xclust");
x = #(1,2,3,4,40,50,60,80,90, 100, 110, 300, 500)~#(10,0,40,60,100,1,-91,20,20,34, 1, 3, -5);
y = #(1,1,1,1,2,1,1,2,3,2, 3, 3, 3)
//Plot tree in TeX
//Change for the appropriate file name here:
filename = "c:\ClassificationTree.tex"
cartdrawpdfclass(x,y,1,1, filename);

Result:
Generates TEX file. Can be then compiled Tex->PS->PDF (Not Tex -> PDF)



Author: R. Timofeev, A. Andriyashin 20041215 license MD*Tech
(C) MD*TECH Method and Data Technologies, 05.02.2006