xy.grid(sfsmisc)
xy.grid()所属R语言包:sfsmisc
Produce regular grid matrix.
生产普通的网格矩阵。
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Produce the grid used by persp, contour, etc, as an N x 2 matrix. This is really outdated by expand.grid() nowadays.
使用persp,轮廓等,产生网格作为N x 2矩阵。这是真正的expand.grid()现在已经过时。
用法----------Usage----------
xy.grid(x, y)
参数----------Arguments----------
参数:x,y
any vectors of same mode.
任何向量相同的模式。
值----------Value----------
a 2-column matrix of “points” for each combination of x and y, i.e. with length(x) * length(y) rows.
2列的矩阵与x行y和length(x) * length(y),即每个组合的“点”。
(作者)----------Author(s)----------
Martin Maechler, 26 Oct 1994.
参见----------See Also----------
expand.grid which didn't exist when
expand.grid不存在时
实例----------Examples----------
plot(xy.grid(1:7, 10*(0:4)))
x <- 1:3 ; y <- 10*(0:4)
xyg <- xy.grid(x,y)
## Compare with expand.grid() :[#比较与expand.grid():]
m2 <- as.matrix(expand.grid(y,x)[, 2:1])
dimnames(m2) <- NULL
stopifnot(identical(xyg, m2))
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|