Re: [R] T and P Statistics

From: Thomas Kaliwe <hamstersquats_at_web.de>
Date: Wed, 25 Jun 2008 17:30:22 +0200

Hi,

help(t.test)

x = rnorm(10, mean = 10, sd = 1) #some data

mytest = t.test(x, mu = 10)               #is mu = 10
attributes(mytest)                              #what's in the test

mytest$p.value      #obtain the p-value

mytest$statistic      #obtain the t-value aka statistic

HTH
Thomas Kaliwe

Tong, Michael schrieb:
> How do you calculate T and P statistics (T- test) in R?
>
> Is there a package out there that can do these calculations?
>
> Best,
>
> Michael Tong
> Futures Associate
> Quantitative Research Services
> Franklin Templeton Investments, Inc.
> 600 Fifth Ave
> New York, NY 10020
> (212) 632-4254
> mtong_at_templeton.com
>
> Notice: All email and instant messages (including attachments) sent to
> or from Franklin Templeton Investments (FTI) personnel may be retained,
> monitored and/or reviewed by FTI and its agents, or authorized
> law enforcement personnel, without further notice or consent.
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help_at_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.
>
>



R-help_at_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. Received on Wed 25 Jun 2008 - 15:39:49 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 25 Jun 2008 - 16:30:53 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive