getellipse(shape)
getellipse()所属R语言包:shape
x-y coordinates of ellipse
椭圆的x-y坐标
译者:生物统计家园网 机器人LoveR
描述----------Description----------
calculates x-y values for (part of) an ellipse; the ellipse can be rotated
计算xy值的(部分)椭圆形;椭圆可以旋转
用法----------Usage----------
getellipse(rx = 1, ry = rx, mid = c(0, 0), dr = 0.01,
angle = 0, from = -pi, to = pi)
参数----------Arguments----------
参数:rx
long radius of ellipse.
椭圆的长半径。
参数:ry
short radius of ellipse.
短半径的椭圆形。
参数:mid
midpoint of ellipse.
椭圆中点。
参数:dr
size of segments, in radians, to specify ellipse (decrease for smoother).
段的大小,弧度为单位,指定椭圆(减少平滑)。
参数:angle
rotation angle, degrees.
旋转角(度)。
参数:from
starting angle for ellipse segment, radians.
椭圆段的起始角度,弧度。
参数:to
final angle for ellipse segment, radians. The segment is generated counterclockwise. The default is draw a full ellipse.
椭圆段的最终角度,弧度。段产生逆时针。默认值是画一个完整的椭圆。
Details
详细信息----------Details----------
rx and ry are the horizontal and vertical radiusses of the ellipses.
rx和ry的椭圆的水平和垂直的radiusses。
points from and to are joined counterclockwise. (this has changed since version 1.3.4).
点from和to加入逆时针。 (这改变了自1.3.4版)。
值----------Value----------
a 2-column matrix with x-y values of the ellipse
与椭圆的x-y的值的2列的矩阵
(作者)----------Author(s)----------
Karline Soetaert <karline.soetaert@nioz.nl>
参见----------See Also----------
plotellipse, filledellipse
plotellipse,filledellipse
实例----------Examples----------
plot(getellipse(1, from = 0, to = pi/2), type = "l", col = "red",
lwd = 2, main = "getellipse")
lines(getellipse(0.5, 0.25, mid = c(0.5, 0.5)), type = "l",
col = "blue", lwd = 2)
lines(getellipse(0.5, 0.25, mid = c(0.5, 0.5), angle = 45),
type = "l", col = "green", lwd = 2)
lines(getellipse(0.2, 0.2, mid = c(0.5, 0.5), from = 0, to = pi/2),
type = "l", col = "orange", lwd = 2)
lines(getellipse(0.2, 0.2, mid = c(0.5, 0.5), from = pi/2, to = 0),
type = "l", col = "black", lwd = 2)
lines(getellipse(0.1, 0.1, mid = c(0.75, 0.5), from = -pi/2, to = pi/2),
type = "l", col = "black", lwd = 2)
emptyplot(main = "getellipse")
col <- femmecol(90)
for (i in seq(0, 180, by = 2))
lines(getellipse(0.5, 0.25, mid = c(0.5, 0.5), angle = i),
type = "l", col = col[(i/2)+1], lwd = 2)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|