plotCSregs1D {pcds} | R Documentation |
The plot of the Central Similarity (CS) Proximity Regions
(vertices jittered along y
-coordinate)
- multiple interval case
Description
Plots the points in and outside of the intervals
based on Yp
points and also the CS proximity regions
(which are also intervals).
If there are duplicates of Yp
or Xp
points,
only one point is retained for each duplicate value,
and a warning message is printed.
CS proximity region is constructed with expansion parameter t>0
and
centrality parameter c \in (0,1)
.
For better visualization, a uniform jitter from U(-Jit,Jit)
(default is Jit=.1
) times range of Xp
and
Yp
and the proximity regions (intervals)) is added to the
y
-direction.
centers
is a logical argument, if TRUE
,
plot includes the centers of the intervals as vertical lines in the plot,
else centers of the intervals are not plotted.
See also (Ceyhan (2016)).
Usage
plotCSregs1D(
Xp,
Yp,
t,
c = 0.5,
Jit = 0.1,
main = NULL,
xlab = NULL,
ylab = NULL,
xlim = NULL,
ylim = NULL,
centers = FALSE,
...
)
Arguments
Xp |
A set of 1D points for which CS proximity regions are plotted. |
Yp |
A set of 1D points which constitute the end points of the intervals which partition the real line. |
t |
A positive real number which serves as the expansion parameter in CS proximity region. |
c |
A positive real number in |
Jit |
A positive real number that determines the amount of jitter along the |
main |
An overall title for the plot (default= |
xlab , ylab |
Titles of the |
xlim , ylim |
Two |
centers |
A logical argument, if |
... |
Additional |
Value
Plot of the CS proximity regions for 1D points located in the middle or end-intervals
based on Yp
points
Author(s)
Elvan Ceyhan
References
Ceyhan E (2016). “Density of a Random Interval Catch Digraph Family and its Use for Testing Uniformity.” REVSTAT, 14(4), 349-394.
See Also
plotCSregs.int
and plotPEregs1D
Examples
t<-2
c<-.4
a<-0; b<-10;
#nx is number of X points (target) and ny is number of Y points (nontarget)
nx<-20; ny<-4; #try also nx<-40; ny<-10 or nx<-1000; ny<-10;
set.seed(1)
xr<-range(a,b)
xf<-(xr[2]-xr[1])*.1
Xp<-runif(nx,a-xf,b+xf)
Yp<-runif(ny,a,b)
plotCSregs1D(Xp,Yp,t,c,xlab="",ylab="")
plotCSregs1D(Xp,Yp+10,t,c,xlab="",ylab="")