Hi there,
I am trying to develop tests of difference for 2 unpaired sets of data from cross-sectional surveys that both used clustering. I want to simply test whether there is a statistical difference from point 1 to point 2 (groups 1 and 2).
I modified the data and produced this output:
. prtest eb, by(svy) cluster(Cluster) rho(0.02)
Two-sample test of proportions
Cluster variable: Cluster
Group: 1 Group: 2
Number of obs = 334 Number of obs = 450
Number of clusters = 38 Number of clusters = 38
Avg. cluster size = 8.79 Avg. cluster size = 11.84
CV cluster size = 0.6676 CV cluster size = 0.5512
Intraclass corr. = 0.0200 Intraclass corr. = 0.0200
------------------------------------------------------------------------------
Group | Mean Std. Err. z P>|z| [95% Conf. Interval]
-------------+----------------------------------------------------------------
1 | .5479042 .0302535 .4886085 .6071999
2 | .1866667 .0208523 .1457969 .2275364
-------------+----------------------------------------------------------------
diff | .3612375 .0367436 .2892214 .4332536
| under Ho: .0383799 9.41 0.000
------------------------------------------------------------------------------
diff = prop(1) - prop(2) z = 9.4122
Ho: diff = 0
Ha: diff < 0 Ha: diff != 0 Ha: diff > 0
Pr(Z < z) = 1.0000 Pr(|Z| > |z|) = 0.0000 Pr(Z > z) = 0.0000
It was suggested to use svy: tabulate twoway, however I was wondering if this would give a similar result. In the example given, I provided dummy ICC. What is the best way to obtain ICCs for the variables?
Thank you for your help in advance!
-Brett
Related Posts with Test of difference - unpaired 2 proportion survey data w/ clustering
Show the working directory and save it in a macroHi~ I can use command cd or pwd to show the working directory. But how can I save the returned resul…
Cleaning string variableDear all, I have a variable called place_birth in my dataset. Some of the locations weren't recorde…
Help with reshaping the dataDear community, I am trying to bring some data into a different format. The data is World Uncertain…
Stata dataset to latex tableI have a dataset in stata that looks like this: quintile mean t_stat 1 0.0100 4.100 2 0.0200 4.200 …
Adding % to stacked bar chartDear statalisters, is there a way to add %-signs (by code) to my stacked bar chart? here is the co…
Subscribe to:
Post Comments (Atom)
0 Response to Test of difference - unpaired 2 proportion survey data w/ clustering
Post a Comment