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

R语言 spatstat包 cut.ppp()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-9-30 13:20:55 | 显示全部楼层 |阅读模式
cut.ppp(spatstat)
cut.ppp()所属R语言包:spatstat

                                        Classify Points in a Point Pattern
                                         点一个点模式分类

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

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

Classifies the points in a point pattern into distinct types according to the numerical marks in the pattern, or according to another variable.
分类成不同的类型的点图案中的点根据在模式中的数值标记,或根据另一个变量。


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


  ## S3 method for class 'ppp'
cut(x, z=marks(x), ...)



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

参数:x
A two-dimensional point pattern. An object of class "ppp".  
一个二维点模式。对象的类"ppp"。


参数:z
Data determining the classification. A numeric vector, a factor, a pixel image, a tessellation, or a string giving the name of a column of marks.  
数据确定的分类。一个数值向量的一个因素,像素的图像,镶嵌,或一个字符串,给出一个列标记的名称。


参数:...
Arguments passed to cut.default. They determine the breakpoints for the mapping from numerical values in z to factor values in the output. See cut.default.  
传递参数到cut.default。他们确定断点z因素值在输出数值的映射。见cut.default。


Details

详细信息----------Details----------

This function has the effect of classifying each point in the point pattern x into one of several possible types. The classification is based on the dataset z, which may be either
此函数具有的分类中的每个点的点图案x到几种可能的类型之一的效果。分类的依据是在数据集上z,它可以是任一

a factor (of length equal to the number of points in z) determining the classification of each point in x. Levels of the factor determine the classification.
的一个因素(长度等于在z)确定的分类x中的每个点的点的数量。因子的水平确定的分类。

a numeric vector (of length equal to the number of points in z). The range of values of z will be divided into bands (the number of bands is determined by ...) and z will be converted to a factor using cut.default.
一个数值向量(长度等于到的点的数量在z)。 z值的范围将分为带(带的数量是由...)和z将被转换到使用cut.default的一个因素。

a pixel image (object of class "im"). The value of z at each point of x will be used as the classifying variable.
像素的图像(类的对象"im"“)。 z在每个点x将用作分级变量的值。

a tessellation (object of class "tess", see tess). Each point of x will be classified according to the tile of the tessellation into which it falls.
一个Tessellation(曲面细分)(对象类"tess",看到tess“)。每个点的x将根据它下降到镶嵌瓷砖的分类。

a character string, giving the name of one of the columns of marks(x), if this is a data frame.
一个字符串,的名称的列marks(x)之一,如果这是一个数据框。

The default is to take z to be the vector of marks in x (or the first column in the data frame of marks of x, if it is a data frame). If the marks are numeric, then the range of values of the numerical marks is divided into several intervals, and each interval is associated with a level of a factor.  The result is a marked point pattern, with the same window and point locations as x, but with the numeric mark of each point discretised by replacing it by the factor level. This is a convenient way to transform a marked point pattern which has numeric marks into a multitype point pattern, for example to plot it or analyse it. See the examples.
默认情况下是采取z是商标的向量x(或标记的数据框中的第一列x,如果它是一个数据框)。如果标记是数字的,那么数值标记的值的范围内被分成多个间隔,和每个时间间隔相关联的电平的一个因素。其结果是一个显着的点图案,具有相同的窗口,并x点位置,但与每个点的离散化由因子水平通过替换它的数字标记。这是一个方便的方式改造成多类型的点模式,例如绘制或分析有数字的标记,一个标记点模式。见的例子。

To select some points from a point pattern, use the subset operator [.ppp instead.
要选择一些点,从点模式的子集,使用操作符[.ppp。


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

A multitype point pattern, that is, a point pattern object (of class "ppp") with a marks vector that is a factor.
一个多类型的模式,也就是一个点模式对象(类"ppp")marks向量,这是一个因素。


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


Adrian Baddeley
<a href="mailto:Adrian.Baddeley@csiro.au">Adrian.Baddeley@csiro.au</a>
<a href="http://www.maths.uwa.edu.au/~adrian/">http://www.maths.uwa.edu.au/~adrian/</a>
and Rolf Turner
<a href="mailto:r.turner@auckland.ac.nz">r.turner@auckland.ac.nz</a>




参见----------See Also----------

cut, ppp.object, tess
cut,ppp.object,tess


实例----------Examples----------


# (1) cutting based on numeric marks of point pattern[(1)切割的基础上数字标记点格局]

data(longleaf)
# Longleaf Pines data[长叶松树数据]
# the marks are positive real numbers indicating tree diameters.[的商标是正实数,表示树的直径。]


## Not run: [#不运行:]
plot(longleaf)

## End(Not run)[#(不执行)]

# cut the range of tree diameters into three intervals[削减范围内的树直径分为三个区间]
long3 <- cut(longleaf, breaks=3)
## Not run: [#不运行:]
plot(long3)

## End(Not run)[#(不执行)]

# adult trees defined to have diameter at least 30 cm[定义为具有直径至少为30厘米的成年树]
long2 <- cut(longleaf, breaks=c(0,30,100), labels=c("Sapling", "Adult"))
plot(long2)
plot(long2, cols=c("green","blue"))

# (2) cutting based on another numeric vector[(2)切割的基础上另一个数字矢量]
# Divide Swedish Pines data into 3 classes[分割瑞典松树数据分为3类]
# according to nearest neighbour distance[根据最近邻距离]

data(swedishpines)
plot(cut(swedishpines, nndist(swedishpines), breaks=3))

# (3) cutting based on tessellation[(3)切割细分]
# Divide Swedish Pines study region into a 4 x 4 grid of rectangles[瑞典松树研究区域分割成4×4的矩形网格]
# and classify points accordingly[和分类分]

tes <- tess(xgrid=seq(0,96,length=5),ygrid=seq(0,100,length=5))
plot(cut(swedishpines, tes))
plot(tes, lty=2, add=TRUE)

# (4) multivariate marks[(4)多元商标]
data(finpines)
cut(finpines, "height", breaks=4)

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


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

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-6-14 11:52 , Processed in 0.020342 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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