Re: [R] compare grupos dichotomus dependent variable

2015-08-07 Thread Bert Gunter
What does this have to do with R programming?

Bert

On Friday, August 7, 2015, AURORA GONZALEZ VIDAL aurora.gonzal...@um.es
wrote:

 Hello everybody. I have a statistics question:

 let's say that I want to compaire answers between men and women to a yes/no
 question but I have so much more women than men, then, it looks like I
 cannot use chi squared test. Would it be correct to use U test (or ranked
 Wilcoxon test)?? What do you think?? The code is below, than you so much!!

 men-rep( 0,12 )
 women - c( 0,1,0,0,0,1,0,0,0,rep( 0,114 ),1,rep( 0,199 ) )
 wilcox.test( men, women )
 chisq.test( men, women )


 --
 Aurora González Vidal

 Sección Apoyo Estadístico.
 Servicio de Apoyo a la Investigación (SAI).
 Vicerrectorado de Investigación.
 Universidad de Murcia
 Edif. SACE . Campus de Espinardo.
 30100 Murcia

 @. aurora.gonzal...@um.es javascript:;
 T. 868 88 7315
 F. 868 88 7302
 www.um.es/sai
 www.um.es/ae

 [[alternative HTML version deleted]]

 __
 R-help@r-project.org javascript:; mailing list -- To UNSUBSCRIBE and
 more, see
 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.



-- 
Bert Gunter

Data is not information. Information is not knowledge. And knowledge is
certainly not wisdom.
   -- Clifford Stoll

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.

Re: [R] compare grupos dichotomus dependent variable

2015-08-07 Thread Jim Lemon
Hi Aurora,
Perhaps what you are seeking is a test of proportions.

prop.test(c(sum(men),sum(women)),c(length(men),length(women)))

2-sample test for equality of proportions with continuity correction

data:  c(sum(men), sum(women)) out of c(length(men), length(women))
X-squared = 1.0378e-30, df = 1, p-value = 1
alternative hypothesis: two.sided
95 percent confidence interval:
 -0.02903701  0.01046116
sample estimates:
 prop 1  prop 2
0.0 0.009287926

Warning message:
In prop.test(c(sum(men), sum(women)), c(length(men), length(women))) :
  Chi-squared approximation may be incorrect

If the question was Have you had a baby in the past year? the answer
is not too far off, but your sample is a bit small.

Jim


On Sat, Aug 8, 2015 at 3:09 AM, AURORA GONZALEZ VIDAL
aurora.gonzal...@um.es wrote:
 Hello everybody. I have a statistics question:

 let's say that I want to compaire answers between men and women to a yes/no
 question but I have so much more women than men, then, it looks like I
 cannot use chi squared test. Would it be correct to use U test (or ranked
 Wilcoxon test)?? What do you think?? The code is below, than you so much!!

 men-rep( 0,12 )
 women - c( 0,1,0,0,0,1,0,0,0,rep( 0,114 ),1,rep( 0,199 ) )
 wilcox.test( men, women )
 chisq.test( men, women )


 --
 Aurora González Vidal

 Sección Apoyo Estadístico.
 Servicio de Apoyo a la Investigación (SAI).
 Vicerrectorado de Investigación.
 Universidad de Murcia
 Edif. SACE . Campus de Espinardo.
 30100 Murcia

 @. aurora.gonzal...@um.es
 T. 868 88 7315
 F. 868 88 7302
 www.um.es/sai
 www.um.es/ae

 [[alternative HTML version deleted]]

 __
 R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
 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.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.

[R] compare grupos dichotomus dependent variable

2015-08-07 Thread AURORA GONZALEZ VIDAL
Hello everybody. I have a statistics question:

let's say that I want to compaire answers between men and women to a yes/no
question but I have so much more women than men, then, it looks like I
cannot use chi squared test. Would it be correct to use U test (or ranked
Wilcoxon test)?? What do you think?? The code is below, than you so much!!

men-rep( 0,12 )
women - c( 0,1,0,0,0,1,0,0,0,rep( 0,114 ),1,rep( 0,199 ) )
wilcox.test( men, women )
chisq.test( men, women )


--
Aurora González Vidal

Sección Apoyo Estadístico.
Servicio de Apoyo a la Investigación (SAI).
Vicerrectorado de Investigación.
Universidad de Murcia
Edif. SACE . Campus de Espinardo.
30100 Murcia

@. aurora.gonzal...@um.es
T. 868 88 7315
F. 868 88 7302
www.um.es/sai
www.um.es/ae

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.