read.mask(secr)
read.mask()所属R语言包:secr
Read Habitat Mask From File
从文件中读人居面膜
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Read coordinates of points on a habitat mask from a text file.
阅读的栖息地面具从一个文本文件上点的坐标。
用法----------Usage----------
read.mask(file = NULL, data = NULL, spacing = NULL, columns = NULL, ...)
参数----------Arguments----------
参数:file
character string with name of text file
字符串,文本文件的名称
参数:data
dataframe
数据框
参数:spacing
spacing of grid points in metres
以米为间距的网格点
参数:columns
character vector naming the columns to save as covariates
字符命名的列向量作为协变量保存
参数:...
other arguments to pass to read.table
到传递read.table的其他参数
Details
详细信息----------Details----------
For file input, the x and y coordinates are usually the first two values on each line, separated by white space. If the file starts with a line of column headers and "header = TRUE" is passed to read.table in the ... argument then "x" and "y" need not be the first two fields.
对于文件的输入,在x和y坐标是通常的前两个值在每一行中,由空格分隔。如果打头的文件的行的列标题“标题= TRUE传递给read.table在...参数,那么x和y的不需要的前两个字段。
data is an alternative input route if the x and y coordinates already exist in R as columns in a dataframe. Only one of data or file should be specified.
data是一种替代的输入路径,如果x和y坐标中已存在的R为列中的数据框。只有一个data或file应符合规定。
The grid cell size spacing should be provided if known. If it is not provided then an attempt is made to infer it from the minimum spacing of points. This can be slow and may demand more memory than is available. In rare cases (highly fragmented masks) it may also yield the wrong answer.
网格单元格大小spacing应,如果知道的话。如果它是不提供然后试图进行推断从它的点的最小间距。这可能是缓慢的,并可能要求更多的内存比。在极少数情况下(高度分散的口罩),它也可能得到错误的答案。
From 2.3.0, additional columns in the input are saved as covariates. The default (columns = NULL) is to save all columns.
2.3.0,其他列中输入保存为协变量。默认值(columns = NULL)是保存的所有列。
值----------Value----------
object of class mask with type "user"
类的对象mask类型为“用户”
注意----------Note----------
The package SPACECAP uses a "state-space" file in "csv" text format with columns "X_COORD", "Y_COORD" and "HABITAT". Such a file may be input directly to read.mask; rows with HABITAT != 1 are dropped.
包SPACECAP使用的“状态空间”的文件,在“CSV”文本格式与列的X_COORD“,”Y_COORD“和”人居“。这样的文件,可直接输入read.mask行,人居署= 1被丢弃。
参见----------See Also----------
mask
mask
实例----------Examples----------
## Replace file name with a valid local name and remove `#'[#替换有效的本地名称和文件名,删除#]
# read.mask (file = "c:\\myfolder\\mask.txt",[read.mask(文件=“C:\ \ MyFolder的\ \ mask.txt”]
# spacing = 3, header = TRUE)[头间距= 3,= TRUE)]
## `mask.txt' should have lines like this[#mask.txt“应该有这样的线]
# x y[X,Y]
# 265 265[265 265]
# 268 265[268 265]
# ...[...]
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|