Yes my mistake,

I looked at the pwr.2p2n.test but i cannot place both n's and both p values
to determine the sig value
e,g *pwr.2p2n.test(h = , n1 = , n2 = , sig.level = , power = )

or am i missing someting obvious?

i did the sam ein SPSS using a macro and the following code:

COMPUTE n1 = Control_MAX .
COMPUTE n2 = Exposed_max.
COMPUTE x1 = Control.
COMPUTE x2 = Exposed.

COMPUTE p1 = x1/n1.
COMPUTE p2 = x2/n2.
COMPUTE phat = (x1 + x2) / (n1 + n2).
COMPUTE SE_phat = SQRT(phat * (1 - phat) * ((1/n1) + (1/n2))).
COMPUTE z = (p1 - p2) /SE_phat.
COMPUTE SIGz_2TL = 2 * (1 - CDFNORM(ABS(z))).
COMPUTE SIGz_LTL = CDFNORM(Z).
COMPUTE SIGz_UTL = 1 - CDFNORM(Z).
COMPUTE SIG_Level = ABS(1-(1-CDFNORM(z))*2).
Compute p1p = p1*100.
Compute p2p = p2*100.
compute diff = p2p-p1p.
EXE.
Var lab p1p "Control Group %".
Var lab p2p "Exposed Group %".



*


On Tue, Jun 17, 2008 at 5:13 PM, Peter Dalgaard <[EMAIL PROTECTED]>
wrote:

> Michael Pearmain wrote:
> > Hi All,
> >
> > I have a table based on ordial data and i want to compare proportions and
> > i've seen in the pwr package i can use
> > power.prop.test
> >
> > however i want to find out what the sig. value is based on n1,n2,p1,p2
> and
> > this package doesn't contain this..
> > Does anyone know of a package that does or is it a case of writting a
> > function specifically for this?
> >
> >
> I think your wired got crossed somewhere:
>
> power.prop.test is not from the pwr package; however, pwr does contain
> pwr.2p2n.test, which looks like it does exactly what you want!
>
>
> > Many thanks in advance
> >
> >       [[alternative HTML version deleted]]
> >
> > ______________________________________________
> > R-help@r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> > and provide commented, minimal, self-contained, reproducible code.
> >
>
>
> --
>   O__  ---- Peter Dalgaard             Ă˜ster Farimagsgade 5, Entr.B
>  c/ /'_ --- Dept. of Biostatistics     PO Box 2099, 1014 Cph. K
>  (*) \(*) -- University of Copenhagen   Denmark      Ph:  (+45) 35327918
> ~~~~~~~~~~ - ([EMAIL PROTECTED])              FAX: (+45) 35327907
>
>
>


-- 
Michael Pearmain
Senior Statistical Analyst


1st Floor, 180 Great Portland St. London W1W 5QZ
t +44 (0) 2032191684
[EMAIL PROTECTED]
[EMAIL PROTECTED]


Doubleclick is a part of the Google group of companies

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to