post.rpart(rpart)
post.rpart()所属R语言包:rpart
PostScript Presentation Plot of an Rpart Object
PostScript的一个软件rpart对象介绍剧情
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Generates a PostScript presentation plot of an rpart object.
生成的PostScript介绍剧情rpart对象。
用法----------Usage----------
post(tree, ...)
## S3 method for class 'rpart'
post(tree, title.,
filename = paste(deparse(substitute(tree)), ".ps", sep = ""),
digits = getOption("digits") - 3, pretty = TRUE,
use.n = TRUE, horizontal = TRUE, ...)
参数----------Arguments----------
参数:tree
fitted model object of class rpart. This is assumed to be the result of some function that produces an object with the same named components as that returned by the rpart function.
拟合模型对象类rpart。这被认为是一些功能,产生一个具有相同的命名组件对象rpart函数返回的结果。
参数:title.
a title which appears at the top of the plot. By default, the name of the rpart endpoint is printed out.
标题出现在剧情的顶部。默认情况下,名称rpart端点被打印出来。
参数:filename
ASCII file to contain the output. By default, the name of the file is the name of the object given by rpart (with the suffix .ps added). If filename = "", the plot appears on the current graphical device.
ASCII文件中包含的输出。默认情况下,文件名是rpart(后缀.ps补充)对象的名称。如果filename = "",图出现在当前的图形设备。
参数:digits
number of significant digits to include in numerical data.
数显着的数字包括在数值数据。
参数:pretty
an integer denoting the extent to which factor levels will be abbreviated in the character strings defining the splits; (0) signifies no abbreviation of levels. A NULL signifies using elements of letters to represent the different factor levels. The default (TRUE) indicates the maximum possible abbreviation.
整数因子水平将在定义的分割的字符串的字符缩写表示程度;(0),标志着没有水平缩写。一个NULL标志使用元素的字母代表不同的因子水平。默认(TRUE)表示最大可能的缩写。
参数:use.n
Logical. If TRUE (default), adds to label (\#events level1/ \#events level2/etc. for method class, n for method anova, and \#events/n for methods poisson and exp).
逻辑。如果TRUE(默认),添加标签(\#事件的方法class,n法anova,\#1级/ \#事件level2/etc。事件/方法列印poisson和exp)。
参数:horizontal
Logical. If TRUE (default), plot is horizontal. If FALSE, plot appears as landscape.
逻辑。如果TRUE(默认),图水平。如果FALSE,图出现作为景观。
参数:...
other arguments to the postscript function.
postscript函数的其他参数。
Details
详情----------Details----------
The plot created uses the functions plot.rpart and text.rpart (with the fancy option). The settings were chosen because they looked good to us, but other options may be better, depending on the rpart object. Users are encouraged to write their own function containing favorite options.
创建该图使用功能plot.rpart和text.rpart(fancy选项)。设置选择,因为他们给我们看了好,但其他选项可能会更好,这取决于rpart对象。鼓励用户写自己喜欢的选项的功能。
副作用----------Side Effects----------
a plot of rpart is created using the postscript driver, or the current device if filename = "".
积了rpart使用postscript驱动程序,或当前的设备,如果filename = ""。
参见----------See Also----------
plot.rpart, rpart, text.rpart, abbreviate
plot.rpart,rpart,text.rpart,abbreviate
举例----------Examples----------
z.auto <- rpart(Mileage ~ Weight, car.test.frame)
post(z.auto, file = "") # display tree on active device[显示树有源器件]
# now construct postscript version on file "pretty.ps"[现在兴建的PostScript版本文件“pretty.ps”]
# with no title[无标题]
post(z.auto, file = "pretty.ps", title = " ")
z.hp <- rpart(Mileage ~ Weight + HP, car.test.frame)
post(z.hp)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|