rowBUTTONS(RPMG)
rowBUTTONS()所属R语言包:RPMG
Geometry for the Really Poor Man's GUI
真正的穷人人的GUI几何
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Create a set of buttons and associated geometry for RPMG
创建一组按钮和相关的几何RPMG
用法----------Usage----------
rowBUTTONS(labs, col = 6, pch = 4, cex=1, boxsize = -1)
参数----------Arguments----------
参数:labs
Vector of labels for the buttons running across the top and bottom of the plot
跑过的图的顶部和底部的按钮标签的向量的
参数:col
Optional vector of colors for the buttons
可选颜色的按钮矢量
参数:pch
Optional vector of symbols to be plotted in the center of the buttons
被绘制在可选的符号向量的按钮中的中心
参数:cex
optional character expansion for text
可选的文本字符扩展
参数:boxsize
optional box size for the buttons, default=-1 where the size is adjusted for string size
可选盒大小的按钮,默认值= -1的大小调整为字符串大小
Details
详细信息----------Details----------
rowBUTTONS is called after the R graphic has been created so the geometry of the buttons can be set. Subsequent calls to whichbutt use the geometry to determine which button has been selected. Some of the parameters chosen here are controlled by par-like parameters.
rowBUTTONS被称为后的R图形可以设置这样的几何形状的按钮中的已创建。随后调用whichbutt使用的几何形状,以确定哪个按钮被选中。这里所选择的参数的控制杆等的参数。
值----------Value----------
The function returns a list of buttons and the associated geometry.
该函数返回一个列表按钮和相关的几何形状。
参数:N
Number of Buttons
按键数
参数:labs
Names of the Buttons
按钮名称
参数:x1
vector of left x-coordinates for the buttons
按钮左侧的x坐标的向量
参数:x2
vector of right x-coordinates for the buttons
向量的合适的x坐标为按钮
参数:y1
vector of top y-coordinates for the buttons
向量的y坐标顶部的按钮
参数:y2
vector of bottom y-coordinates for the buttons
向量的底部的y坐标为按钮
注意----------Note----------
rowBUTTONS uses the current plotting parameters from par() to set the geometry. If the window is resized, rowBUTTONS should be reset to extract correct button position. In interactive mode this is done each time the plot is refreshed.
rowBUTTONS杆()使用当前的绘图参数设置几何。如果调整窗口的大小,rowBUTTONS应该重置提取正确的按钮位置。在交互模式下,这样做是每次刷新该图。
(作者)----------Author(s)----------
Jake Anderson and Jonathan M. Lees<jonathan.lees@unc.edu>
参见----------See Also----------
whichbutt, par
whichbutt,票面
实例----------Examples----------
####### create a plot[######创建一个图]
plot(c(0,1), c(0,1))
####### set the character vector of button labels[######设置字符向量的按钮标签]
mybutts = c("DONE", "REFRESH", "rainbow", "topo", "terrain", "CONT",
"XSEC","PS" )
######### set colors and plotting chars for buttons[########设置颜色和绘制字符的按钮]
colabs = rep(1, length=length(mybutts))
pchlabs = rep(0,length(mybutts))
####### create and set geometry for buttons:[######创建和设置几何形状的按钮:]
buttons = rowBUTTONS(mybutts, col=colabs, pch=pchlabs)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|