pixellate.psp(spatstat)
pixellate.psp()所属R语言包:spatstat
Convert Line Segment Pattern to Pixel Image
像素图像转换线段模式
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Converts a line segment pattern to a pixel image by measuring the length of lines intersecting each pixel.
通过测量每个像素的线交叉的长度转换为线段图案的像素图像。
用法----------Usage----------
## S3 method for class 'psp'
pixellate(x, W=NULL, ..., weights = NULL)
参数----------Arguments----------
参数:x
Line segment pattern (object of class "psp").
线段模式(类的对象"psp")。
参数:W
Optional window (object of class "owin") determining the pixel resolution.
可选窗口(对象类"owin")确定像素的分辨率。
参数:...
Optional arguments passed to as.mask to determine the pixel resolution.
可选参数传递给as.mask,以确定像素的分辨率。
参数:weights
Optional vector of weights associated with each line segment.
可选矢量与每个线段相关联的权重。
Details
详细信息----------Details----------
This function converts a line segment pattern to a pixel image by computing, for each pixel, the total length of intersection between the pixel and the line segments.
这个函数转换线段图案的像素的图像,通过计算,对每一个像素之间的像素和线段的总长度的交点。
This is a method for the generic function pixellate for the class of line segment patterns.
这是一个方法的通用函数pixellate线段模式类。
The pixel raster is determined by W and the optional arguments .... If W is missing or NULL, it defaults to the window containing x. Then W is converted to a binary pixel mask using as.mask. The arguments ... are passed to as.mask to control the pixel resolution.
的像素栅格是由W和可选的参数...。如果W丢失或NULL,它默认的窗口,其中包含x。然后W被转换为一个二进制像素掩模使用as.mask。这些参数...传递给as.mask控制像素的分辨率。
If weights are given, then the length of the intersection between line segment i and pixel j is multiplied by weights[i] before the lengths are summed for each pixel.
如果weights给出,则线段之间的交点的长度i和像素j被乘以weights[i]的长度之前,对于每个像素相加。
值----------Value----------
A pixel image (object of class "im") with numeric values.
像素图像(对象类"im")的数值。
(作者)----------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----------
pixellate, as.mask, as.mask.psp.
pixellate,as.mask,as.mask.psp。
Use as.mask.psp if you only want to know which pixels are intersected by lines.
使用as.mask.psp,如果你只是想知道哪些像素相交的线。
实例----------Examples----------
X <- psp(runif(10),runif(10), runif(10), runif(10), window=owin())
plot(pixellate(X))
plot(X, add=TRUE)
sum(lengths.psp(X))
sum(pixellate(X))
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|