funsMuVarCS1D | R Documentation |
Two functions: muCS1D
and asy.varCS1D
.
muCS1D
returns the mean of the (arc) density of CS-PCD
and asy.varCS1D
returns the (asymptotic) variance of the arc density of CS-PCD
for a given centrality parameter c \in (0,1)
and an expansion parameter t>0
and 1D uniform data in a
finite interval (a,b)
, i.e., data from U(a,b)
distribution.
See also (\insertCiteceyhan:revstat-2016;textualpcds).
muCS1D(t, c)
asy.varCS1D(t, c)
t |
A positive real number which serves as the expansion parameter in CS proximity region. |
c |
A positive real number in |
muCS1D
returns the mean and asy.varCS1D
returns the asymptotic variance of the
arc density of CS-PCD for uniform data in an interval
Elvan Ceyhan
muPE1D
and asy.varPE1D
#Examples for muCS1D
muCS1D(1.2,.4)
muCS1D(1.2,.6)
tseq<-seq(0.01,5,by=.05)
cseq<-seq(0.01,.99,by=.05)
ltseq<-length(tseq)
lcseq<-length(cseq)
mu.grid<-matrix(0,nrow=ltseq,ncol=lcseq)
for (i in 1:ltseq)
for (j in 1:lcseq)
{
mu.grid[i,j]<-muCS1D(tseq[i],cseq[j])
}
persp(tseq,cseq,mu.grid, xlab="t", ylab="c", zlab="mu(t,c)",theta = -30,
phi = 30, expand = 0.5, col = "lightblue", ltheta = 120,
shade = 0.05, ticktype = "detailed")
#Examples for asy.varCS1D
asy.varCS1D(1.2,.8)
tseq<-seq(0.01,5,by=.05)
cseq<-seq(0.01,.99,by=.05)
ltseq<-length(tseq)
lcseq<-length(cseq)
var.grid<-matrix(0,nrow=ltseq,ncol=lcseq)
for (i in 1:ltseq)
for (j in 1:lcseq)
{
var.grid[i,j]<-asy.varCS1D(tseq[i],cseq[j])
}
persp(tseq,cseq,var.grid, xlab="t", ylab="c", zlab="var(t,c)", theta = -30,
phi = 30, expand = 0.5, col = "lightblue", ltheta = 120,
shade = 0.05, ticktype = "detailed")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.