Message-ID: <4975D089.6000804@biostat.ku.dk>
Date: 2009-01-20T13:24:25Z
From: Peter Dalgaard
Subject: Do not want to print when using prop.test
In-Reply-To: <C9328F0EEDC3BC439FDABD12060E9109765220@erini1.ERINI.local>
Jose Iparraguirre D'Elia wrote:
> I am using the function prop.test (base package), which returns a
> list with class "htest". All I want to do is to assign one of its
> values to a variable, but I do not want R to print the results and added warning
message whenever I invoke the function.
> How can I prevent R from printing on using prop.test?
> Regards,
> Jos? Luis
By assigning one of its values...
> pval <- prop.test(heads, 100)$p.value
> pval
[1] 0.4839273
--
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
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907