plotor: Empirical odds rate plot

Description Usage Arguments Details Author(s) References Examples

View source: R/plotor.R

Description

Plot the empirical odds rate based on empirical distributions of the two samples

Usage

1
plotor(x, y, ...)

Arguments

x,y

Vectirs containing the data values of the two samples x1,...,xm and y1,...,yn.

...

other arguments for plot.

Details

See the reference below.

Author(s)

Zhong Guan <zguan@iusb.edu>

References

Zhong Guan and Cheng Peng (2011), "A rank-based empirical likelihood approach to two-sample proportional odds model and its goodness-of-fit", Journal of Nonparametric Statistics, to appear.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
# Use radar tube life data
z<-RadarTube$Days
v<-RadarTube$Type
x<-z[v==1]; y<-z[v==2]
# Dabrowska-Doksum's estimate of theta
theta0.hat<-dd.est(x,y)
vartheta0.hat<-dd.est(y,x)
# MRLE of theta
m<-length(x); n<-length(y)
N<-m+n; lambda<-m/N
phat0<-phi(N, theta0.hat, lambda)/N
theta.hat<-mrle.sporm(x, y, theta0.hat, phat0)$theta
## Empirical Odds Raio Plot
plotor(x, y, main="Empirical Odds Ratio Plot", lwd=2, ylim=c(0,2))
abline(h=theta.hat, lwd=2,lty=2, col=2)
abline(h=1/vartheta0.hat, lwd=2,lty=3, col=3)
abline(h=theta0.hat, lwd=2,lty=4, col=4)

sporm documentation built on Jan. 27, 2021, 5:08 p.m.