cl2edges.vert.reg.basic.tri {pcds} | R Documentation |
The closest points among a data set in the vertex regions to the corresponding edges in a standard basic triangle
Description
An object of class "Extrema"
.
Returns the closest data points among the data set, Xp
,
to edge i
in M
-vertex region i
for i=1,2,3
in the standard basic triangle T_b=T(A=(0,0),B=(1,0),C=(c_1,c_2))
where c_1
is in [0,1/2]
, c_2>0
and (1-c_1)^2+c_2^2 \le 1
.
Vertex labels are A=1
, B=2
, and C=3
,
and corresponding edge labels are BC=1
, AC=2
, and AB=3
.
Vertex regions are based on center M=(m_1,m_2)
in Cartesian coordinates or
M=(\alpha,\beta,\gamma)
in barycentric coordinates
in the interior of the standard basic triangle T_b
or based on the circumcenter of T_b
.
Any given triangle can be mapped to the standard basic triangle by a combination of rigid body motions (i.e., translation, rotation and reflection) and scaling, preserving uniformity of the points in the original triangle. Hence, standard basic triangle is useful for simulation studies under the uniformity hypothesis.
See also (Ceyhan (2005, 2010)).
Usage
cl2edges.vert.reg.basic.tri(Xp, c1, c2, M)
Arguments
Xp |
A set of 2D points representing the set of data points. |
c1 , c2 |
Positive real numbers
which constitute the vertex of the standard basic triangle
adjacent to the shorter edges; |
M |
A 2D point in Cartesian coordinates
or a 3D point in barycentric coordinates
which serves as a center
in the interior of the standard basic triangle |
Value
A list
with the elements
txt1 |
Vertex labels are |
txt2 |
A short description of the distances
as |
type |
Type of the extrema points |
desc |
A short description of the extrema points |
mtitle |
The |
ext |
The extrema points, here, closest points to edges in the corresponding vertex region. |
X |
The input data, |
num.points |
The number of data points, i.e., size of |
supp |
Support of the data points, here, it is |
cent |
The center point used for construction of vertex regions |
ncent |
Name of the center, |
regions |
Vertex regions inside the triangle, |
region.names |
Names of the vertex regions
as |
region.centers |
Centers of mass of the vertex regions
inside |
dist2ref |
Distances of closest points in the vertex regions to corresponding edges. |
Author(s)
Elvan Ceyhan
References
Ceyhan E (2005).
An Investigation of Proximity Catch Digraphs in Delaunay Tessellations, also available as technical monograph titled Proximity Catch Digraphs: Auxiliary Tools, Properties, and Applications.
Ph.D. thesis, The Johns Hopkins University, Baltimore, MD, 21218.
Ceyhan E (2010).
“Extension of One-Dimensional Proximity Regions to Higher Dimensions.”
Computational Geometry: Theory and Applications, 43(9), 721-748.
Ceyhan E (2011).
“Spatial Clustering Tests Based on Domination Number of a New Random Digraph Family.”
Communications in Statistics - Theory and Methods, 40(8), 1363-1395.
See Also
cl2edgesCMvert.reg
, cl2edgesMvert.reg
,
and cl2edges.std.tri
Examples
c1<-.4; c2<-.6
A<-c(0,0); B<-c(1,0); C<-c(c1,c2);
Tb<-rbind(A,B,C);
set.seed(1)
n<-20
Xp<-runif.basic.tri(n,c1,c2)$g
M<-as.numeric(runif.basic.tri(1,c1,c2)$g) #try also M<-c(.6,.3)
Ext<-cl2edges.vert.reg.basic.tri(Xp,c1,c2,M)
Ext
summary(Ext)
plot(Ext)
cl2e<-Ext
Ds<-prj.cent2edges.basic.tri(c1,c2,M)
Xlim<-range(Tb[,1],Xp[,1])
Ylim<-range(Tb[,2],Xp[,2])
xd<-Xlim[2]-Xlim[1]
yd<-Ylim[2]-Ylim[1]
plot(Tb,pch=".",xlab="",ylab="",
main="Closest Points in M-Vertex Regions \n to the Opposite Edges",
axes=TRUE,xlim=Xlim+xd*c(-.05,.05),ylim=Ylim+yd*c(-.05,.05))
polygon(Tb)
points(Xp,pch=1,col=1)
L<-rbind(M,M,M); R<-Ds
segments(L[,1], L[,2], R[,1], R[,2], lty=2)
points(cl2e$ext,pch=3,col=2)
xc<-Tb[,1]+c(-.02,.02,0.02)
yc<-Tb[,2]+c(.02,.02,.02)
txt.str<-c("A","B","C")
text(xc,yc,txt.str)
txt<-rbind(M,Ds)
xc<-txt[,1]+c(-.02,.04,-.03,0)
yc<-txt[,2]+c(-.02,.02,.02,-.03)
txt.str<-c("M","D1","D2","D3")
text(xc,yc,txt.str)