plotStep(sfsmisc)
plotStep()所属R语言包:sfsmisc
Plot a Step Function
绘制一个阶梯函数
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Plots a step function f(x)= sum(i; y[i] * Ind[t[i-1], t[i])(x)), i.e., a piecewise constant function of one variable. With one argument, plots the empirical cumulative distribution function.
绘制一个阶跃函数F(X)=sum(i; y[i] * Ind[t[i-1], t[i])(x)),即一个分段常数函数的一个变量。带一个参数,绘制经验累积分布函数。
用法----------Usage----------
plotStep(ti, y,
cad.lag = TRUE,
verticals = !cad.lag,
left.points= cad.lag, right.points= FALSE, end.points= FALSE,
add = FALSE,
pch = par('pch'),
xlab=deparse(substitute(ti)), ylab=deparse(substitute(y)),
main=NULL, ...)
参数----------Arguments----------
参数:ti
numeric vector = X[1:N] or t[0:n].
数字矢量=X[1:N]或t[0:n]。
参数:y
numeric vector y[1:n]; if omitted take y = k/N for empirical CDF.
数字矢量y[1:n];如果省略Ÿ= K / N的经验CDF。
参数:cad.lag
logical: Draw 'cad.lag', i.e., “continue 脿 droite, limite 脿 gauche”. Default = TRUE.
逻辑:抽奖“cad.lag”,即“继续LIMITEààDROITE,笨拙的”。默认= TRUE。
参数:verticals
logical: Draw vertical lines? Default= ! cad.lag
逻辑:绘制垂直线?默认值=! cad.lag
参数:left.points
logical: Draw left points? Default= cad.lag
逻辑:绘制左点吗?默认值=cad.lag
参数:right.points
logical: Draw right points? Default= FALSE
逻辑:画出正确的点?默认值=FALSE
参数:end.points
logical: Draw 2 end points? Default= FALSE
逻辑:抽2点吗?默认值=FALSE
参数:add
logical: Add to existing plot? Default= FALSE
逻辑:添加到现有的图吗?默认值=FALSE
参数:pch
plotting character for points, see par().
绘制字符的点,请参阅par()。
参数:xlab,ylab
labels of x- and y-axis
标签的x-和y-轴
参数:main
main title; defaults to the call' if you do not want a title, use main = "".
主标题,默认打的检测,如果你不希望有一个标题,使用main = ""。
参数:...
Any valid argument to plot(..).
任何有效的参数plot(..)。
值----------Value----------
invisibly: List with components t and y.
不可见的:与组件t和y名单。
副作用----------Side Effects----------
Calls plot(..), points(..), segments(..) appropriately and plots on current graphics device.
呼叫图(..),点(..),分类(..)适当和当前图形设备的图上。
(作者)----------Author(s)----------
Martin Maechler, Seminar for Statistics, ETH Zurich,
<a href="mailto:maechler@stat.math.ethz.ch">maechler@stat.math.ethz.ch</a>, 1991 ff.
参见----------See Also----------
The plot methods plot.ecdf and plot.stepfun in R which are conceptually nicer.
plot方法plot.ecdf和plot.stepfunR中的概念是更好的。
segments(..., method = "constant").
segments(..., method = "constant")。
实例----------Examples----------
##-- Draw an Empirical CDF (and see the default title ..)[# - 绘制的实证CDF(看到默认的标题。)]
plotStep(rnorm(15))
plotStep(runif(25), cad.lag=FALSE)
plotStep(runif(25), cad.lag=FALSE, add=TRUE, lty = 2)
ui <- sort(runif(20))
plotStep(ui, ni <- cumsum(rpois(19, lambda=1.5) - 1.5), cad.lag = FALSE)
plotStep(ui, ni, verticals = TRUE, right.points = TRUE)
plotStep(rnorm(201), pch = '.') #- smaller points[ - 小了点]
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|