找回密码
 注册
查看: 3162|回复: 0

R语言:plot.ts()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-16 20:00:10 | 显示全部楼层 |阅读模式
plot.ts(stats)
plot.ts()所属R语言包:stats

                                        Plotting Time-Series Objects
                                         绘制时间序列的对象

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

Plotting method for objects inheriting from class "ts".
绘制类"ts"继承对象的方法。


用法----------Usage----------


## S3 method for class 'ts'
plot(x, y = NULL, plot.type = c("multiple", "single"),
        xy.labels, xy.lines, panel = lines, nc, yax.flip = FALSE,
        mar.multi = c(0, 5.1, 0, if(yax.flip) 5.1 else 2.1),
        oma.multi = c(6, 0, 5, 0), axes = TRUE, ...)

## S3 method for class 'ts'
lines(x, ...)



参数----------Arguments----------

参数:x, y
time series objects, usually inheriting from class "ts".
时间序列的对象,通常继承从类"ts"。


参数:plot.type
for multivariate time series, should the series by plotted separately (with a common time axis) or on a single plot?
多变量时间序列,应通过一系列策划分开(有一个共同的时间轴)或一个单一的图吗?


参数:xy.labels
logical, indicating if text() labels should be used for an x-y plot, or character, supplying a vector of labels to be used.  The default is to label for up to 150 points, and not for more.
逻辑,表示如果text()标签应当用于XY坐标图,或性格,提供使用的标签的向量。默认是高达150点,而不是更多的标签。


参数:xy.lines
logical, indicating if lines should be drawn for an x-y plot.  Defaults to the value of xy.labels if that is logical, otherwise to TRUE.
逻辑,表明lines如果应为XY坐标图绘制。默认值xy.labels如果这是逻辑,否则TRUE。


参数:panel
a function(x, col, bg, pch, type, ...) which gives the action to be carried out in each panel of the display for plot.type="multiple".  The default is lines.
function(x, col, bg, pch, type, ...)给plot.type="multiple"在每个显示面板进行操作。默认lines。


参数:nc
the number of columns to use when type="multiple". Defaults to 1 for up to 4 series, otherwise to 2.
列数使用时type="multiple"。默认为1到4个系列,另有2。


参数:yax.flip
logical indicating if the y-axis (ticks and numbering) should flip from side 2 (left) to 4 (right) from series to series when type="multiple".
逻辑表示y轴(刻度线和编号),如果要翻转从侧面2(左)到4(右)从系列系列type="multiple"。


参数:mar.multi, oma.multi
the (default) par settings for plot.type="multiple".  Modify with care!
“(默认)par的设置为plot.type="multiple"。修改小心!


参数:axes
logical indicating if x- and y- axes should be drawn.
逻辑表明,如果x和y轴应制定。


参数:...
additional graphical arguments, see plot, plot.default and par.
额外的图形参数,看到plot,plot.default和par。


Details

详情----------Details----------

If y is missing, this function creates a time series plot, for multivariate series of one of two kinds depending on plot.type.
y如果缺少,这个函数创建一个时间序列图,两个种上plot.type多元系列。

If y is present, both x and y must be univariate, and a scatter plot y ~ x will be drawn, enhanced by using text if xy.labels is TRUE or character, and lines if xy.lines is TRUE.
如果y的是目前,无论是x和y必须是单因素,并绘制散点图y ~ x将通过增强text如果<X >是xy.labels或TRUE,character如果lines是xy.lines。


参见----------See Also----------

ts for basic time series construction and access functionality.
ts基本时间序列的建设和接入功能。


举例----------Examples----------


require(graphics)

## Multivariate[#多元]
z <- ts(matrix(rt(200 * 8, df = 3), 200, 8),
        start = c(1961, 1), frequency = 12)
plot(z, yax.flip = TRUE)
plot(z, axes = FALSE, ann = FALSE, frame.plot = TRUE,
     mar.multi = c(0,0,0,0), oma.multi = c(1,1,5,1))
title("plot(ts(..), axes=FALSE, ann=FALSE, frame.plot=TRUE, mar..., oma...)")

z <- window(z[,1:3], end = c(1969,12))
plot(z, type = "b")    # multiple[多种]
plot(z, plot.type="single", lty=1:3, col=4:2)

## A phase plot:[#A相图:]
plot(nhtemp, c(nhtemp[-1], NA), cex = .8, col="blue",
     main = "Lag plot of New Haven temperatures")
## a clearer way to do this would be[#更清晰的方式做,这将是]
## Not run: [#无法运行:]
plot(nhtemp, lag(nhtemp, 1), cex = .8, col="blue",
     main = "Lag plot of New Haven temperatures")

## End(Not run)[#结束(不运行)]

## xy.lines and xy.labels are FALSE for large series:[#xy.lines和xy.labels是假大系列:]
plot(lag(sunspots, 1), sunspots, pch = ".")

SMI <- EuStockMarkets[, "SMI"]
plot(lag(SMI,  1), SMI, pch = ".")
plot(lag(SMI, 20), SMI, pch = ".", log = "xy",
     main = "4 weeks lagged SMI stocks -- log scale", xy.lines= TRUE)

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2025-5-6 07:11 , Processed in 0.020359 second(s), 15 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表