[R] Code Verification

pantd@unlv.nevada.edu pantd at unlv.nevada.edu
Tue Jul 19 19:28:50 CEST 2005


Hi R Users
I have a code which I am running for my thesis work. Just want to make sure that
its ok. Its a t test I am conducting between two gamma distributions with
different shape parameters.

the code looks like:

sink("a1.txt");

for (i in 1:1000)
{
x<-rgamma(40, 2.5, 10)  # n = 40, shape = 2.5, Scale = 10
y<-rgamma(40, 2.8, 10)  # n = 40, shape = 2.8, Scale = 10
z<-t.test(x, y)
print(z)
}


I will appreciate it if someone could tell me if its alrite or not.

thanks

-dev




More information about the R-help mailing list