Dear all, I am a biologist. I have two sets of distance P(start1, end1) and Q(start2, end2). The distance will be like this. P ------------------------ Q ---------------------------------------- I want to know whether P falls closely to the right end or left end of Q. P and Q are of different lengths for each data point. There are more than 10000 pairs of P and Q. Is there any test or function in R to bring a statistically significant conclusion. Thanks for all, Suku [[alternative HTML version deleted]]
First of all, read the posting guide carefully : http://www.R-project.org/posting-guide.html Your question is far from clear. When you say that the lengths of P and Q are different, you mean the length of the data or the difference between start and end? That makes a world of difference. Regarding the statistical test, that depends on what your data represents. Is it possible for P to fall close to the left and the right : P ------------------------- Q --------------------------- For example. You should also specify which test you want to use. Then people on the list will be able to tell you whether that is available in R. You can off course construct your own test with the tools R provides, but again, this requires a lot more information. Next to that, the list is actually not intended for statistical advice, but for advice regarding R code. Maybe somebody will join in with some statistical guidance, but if you don't know what to do, you better consult a statistician at your departement. Cheers Joris On Thu, Jul 1, 2010 at 1:53 PM, ravikumar sukumar <ravikumarsukumar at gmail.com> wrote:> Dear all, > I am a biologist. I have two sets of distance P(start1, end1) and Q(start2, > end2). > The distance will be like this. > P ? ? ? ? ------------------------ > Q ?---------------------------------------- > > I want to know whether P falls closely to the right end or left ?end of Q. > ?P and Q are of different lengths for each data point. There are more than > 10000 pairs of P and Q. > Is there any test or function in R to bring a statistically significant > conclusion. > > Thanks for all, > Suku > > ? ? ? ?[[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. >-- Joris Meys Statistical consultant Ghent University Faculty of Bioscience Engineering Department of Applied mathematics, biometrics and process control tel : +32 9 264 59 87 Joris.Meys at Ugent.be ------------------------------- Disclaimer : http://helpdesk.ugent.be/e-maildisclaimer.php
Suku, It looks like you might want to consult with a [bio]statistician, but I'm interested in what these distances represent. Can you give some additional context for your problem? How were these distances collected? Is it a collection of pairs of intervals, like this: P Q 1) (1.5, 1.8) (1.2, 2.0) 2) (1.4, 1.9) (1.4, 2.3) ... 10000) (start1, end1) (start2, end2) ? If so, is there a more specific test you're interested in? For instance, whether the interval P overlaps with the start/stop position of interval Q, or whether start1 == start2, or end1 == end2, or both? I can think of a bootstrap test for hypotheses like this, and this is relatively easy in R. -Matt On Thu, 2010-07-01 at 07:53 -0400, ravikumar sukumar wrote:> Dear all, > I am a biologist. I have two sets of distance P(start1, end1) and Q(start2, > end2). > The distance will be like this. > P ------------------------ > Q ---------------------------------------- > > I want to know whether P falls closely to the right end or left end of Q. > P and Q are of different lengths for each data point. There are more than > 10000 pairs of P and Q. > Is there any test or function in R to bring a statistically significant > conclusion. > > Thanks for all, > Suku > > [[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.-- Matthew S. Shotwell Graduate Student Division of Biostatistics and Epidemiology Medical University of South Carolina http://biostatmatt.com
On Jul 1, 2010, at 7:53 AM, ravikumar sukumar wrote:> Dear all, > I am a biologist. I have two sets of distance P(start1, end1) and > Q(start2, > end2). > The distance will be like this. > P ------------------------ > Q ---------------------------------------- > > I want to know whether P falls closely to the right end or left end > of Q. > P and Q are of different lengths for each data point.Do you want to know whether P(start1) - Q(Start2) < P(end1) - Q(end2) The arithmetic operators and comparison operators are vectorized.> There are more than > 10000 pairs of P and Q.You could offer an example: ?head> Is there any test or function in R to bring a statistically > significant > conclusion.?binom.test # if my interpretation above is what you were asking.> > Thanks for all, > Suku > > [[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.David Winsemius, MD West Hartford, CT
On Jul 1, 2010, at 9:00 AM, David Winsemius wrote:> > On Jul 1, 2010, at 7:53 AM, ravikumar sukumar wrote: > >> Dear all, >> I am a biologist. I have two sets of distance P(start1, end1) and >> Q(start2, >> end2). >> The distance will be like this. >> P ------------------------ >> Q ---------------------------------------- >> >> I want to know whether P falls closely to the right end or left >> end of Q. >> P and Q are of different lengths for each data point. > > Do you want to know whetherShould have been : abs( P(start1) - Q(Start2) ) < abs( P(end1) - Q(end2) )> > The arithmetic operators and comparison operators are vectorized. > >> There are more than >> 10000 pairs of P and Q. > > You could offer an example: > > ?head > >> Is there any test or function in R to bring a statistically >> significant >> conclusion. > > ?binom.test # if my interpretation above is what you were asking. > >> >> Thanks for all,>David Winsemius, MD West Hartford, CT