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

R语言 EBImage包 drawtext()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-25 16:53:26 | 显示全部楼层 |阅读模式
drawtext(EBImage)
drawtext()所属R语言包:EBImage

                                        Draw text on images.
                                         图像上绘制文本。

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

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

Draws text on images.
绘制图像上的文字。


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


  drawtext(img, xy, labels, font, col)
   
  drawfont(family=switch(.Platform$OS.type, windows="Arial", "helvetica"),
           style="n", size=14, weight=200, antialias=TRUE)



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

参数:img
An Image object or an array.
Image对象或数组。


参数:xy
Matrix (or a list of matrices if img contains multiple frames)  of coordinates of labels.
矩阵(或一矩阵列表img如果包含多个帧),标签的坐标。


参数:labels
A character vector (or a list of vectors if img contains multiple frames)  containing the labels to be output.
含有标签输出一个字符的矢量(或向量列表img如果包含多个帧)。


参数:font
A font object, returned by drawfont. If missing, a default OS-dependent font will be chosen.
一个Font对象,返回drawfont。如果丢失,依赖于操作系统的默认字体将被选择。


参数:col
A character vector of font colors.
一个特征向量字体颜色。


参数:family
A character value indicating the font family to use. Valid examples on Linux/UNIX systems include helvetica, times, courier and symbol. Valid examples on Windows machines  include TrueType like Arial and Verdana.
一个字符值,该值指示字体家庭使用。 Linux / UNIX系统上的有效的例子包括helvetica,times,courier和symbol。有效的例子包括在Windows机器上的TrueType像Arial和Verdana。


参数:style
A character value specifying the font style to use.  Supported styles are: normal (default), italic,  and oblique.  
一个字符值,指定使用的字体样式。支持的风格是:normal(默认),italic,oblique。


参数:size
Font size in points.
字体大小点。


参数:weight
A numeric value indicating the font weight (bold font). Supported values range between 100 and 900.
一个数值,表示字体的粗细(粗体)。支持的值介于100和900。


参数:antialias
A logical value indicating whether the font should be  anti-aliased.
一个逻辑值,该值指示字体是否应该反锯齿。


值----------Value----------

An Image object or an array, containing the transformed version of img.
一个Image对象或数组,包含img的转换版本。


作者(S)----------Author(s)----------



Oleg Sklyar, <a href="mailtosklyar@ebi.ac.uk">osklyar@ebi.ac.uk</a>, 2007




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


  lena = readImage(system.file("images", "lena-color.png", package="EBImage"))
  font = drawfont(weight=600, size=28)
  lena = drawtext(lena, xy=c(250, 450), labels="Lena", font=font, col="white")
  if (interactive()) display(lena)

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


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

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-2-11 17:07 , Processed in 0.019638 second(s), 15 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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