Displaying 3 results from an estimated 3 matches for "zstar".
Did you mean:
star
2013 Apr 30
1
Question regarding error "x and y lengths differ"
...we can compute a confidence interval for our measure
of the
population mean for each one of our samples. Now let¢s compute and plot the
confidence intervals for the 50 samples:> m = 50; n = 40; mu = mean(pop);
sigma = sd(pop);
> SE = sigma/sqrt(n) # Standard error in mean
> alpha = 0.10 ; zstar = qnorm(1-alpha/2); # Find z for 90%
confidence
> matplot(rbind( samp_mean - zstar*SE, samp_mean +
zstar*SE),rbind(1:m,1:m), type="l", lty=1);
> abline(v=mu)
I am receiving the error "Error in xy.coords(x, y, xlabel, ylabel, log =
log) :
'x' and 'y' lengths d...
2013 Apr 03
1
prop.test vs hand calculated confidence interval
Hi,
This code:
n=40
x=17
phat=x/n
SE=sqrt(phat*(1-phat)/n)
zstar=qnorm(0.995)
E=zstar*SE
phat+c(-E,E)
Gives this result:
[1] 0.2236668 0.6263332
The TI Graphing calculator gives the same result.
Whereas this test:
prop.test(x,n,conf.level=0.99,correct=FALSE)
Give this result:
0.2489036 0.6224374
I'm wondering why there is a difference.
D.
--
Vie...
2009 Apr 23
2
Two 3D cones in one graph
...[2]))
xstar<-seq(-astar,astar,len=50)
ystar<-seq(-bstar,bstar,len=50)
g<-expand.grid(x=xstar,y=ystar)
p1<-2*g$x*mu[1]/a**2+2*g$y*mu[2]/b**2
p2<-(g$x**2/a**2+g$y**2/b**2)
p3<-mu[1]**2/a**2+mu[2]**2/b**2-1
q<-(p1+sqrt(p1**2-4*p2*p3))/(2*p2)
z<-sqrt(1-(q*g$x)**2-(q*g$y)**2)
zstar<-(z/q)
ind0<-!(q<1)
g$z<-zstar
sc<-matrix(c(rep(c(-1,-1,-1),sum(ind0))),nrow=sum(ind0),byrow=TRUE)
gstar<-rbind(g[ind0,],sc*g[ind0,])
group<-c(rep(1,nrow(gstar)/2),rep(2,nrow(gstar)/2))
gstar$group<-group
wireframe(z~x*y|group,gstar,colorkey=TRUE,drape=TRUE,
scales=list(...