2
$\begingroup$

23 patients suffering from bruxism (grinding of teeth) have been given a treatment. Their baseline bruxism has been measured for three nights, then they were treated for 23 nights, then again the "post" baseline was measured for three nights.

The raw data looks like this:

patient night   score   duration    minutes of sleep
1       1       20      25          480
1       2       28      67          480

The values are:

  • patient = patient number
  • night = night (1 to 26)
  • score = total number of bruxism attacks during that night
  • duration = total seconds of bruxism (sum over all attacks) for that night
  • minutes of sleep = the observed timespan (rounded to a quarter hour)

In all, there are 598 datasets, 26 consecutive nights for 23 different patients.

The interesting variables have been defined as:

nph = number of bruxism attacks per hour (score * 60 / minutes of sleep) sph = duration of bruxism in seconds per hour (duration * 60 / minutes of sleep)

The nightly means over all patients are:

nph <- c(8.808858, 8.364923, 11.932373, 9.108704, 8.135258, 6.886013, 6.379688, 6.034062, 5.731728, 5.823831, 5.128421, 4.526408, 5.145101, 5.860569, 7.691637, 5.645240, 5.151750, 7.496109, 5.375605, 5.994595, 5.650951, 6.459269, 4.490204, 7.891916, 7.684742, 7.583042)
sph <- c(23.528665, 16.382689, 29.492815, 23.752084, 19.966185, 16.104159, 15.135596, 13.218658, 11.626881, 11.321739, 13.418337, 8.391212, 9.062977, 10.665424, 9.535756, 9.925929, 9.040313, 14.635182, 8.549451, 10.346057, 9.742318, 16.437902, 7.443140, 14.204343, 12.648306, 13.401150)

These are mean number of bruxism attacks per hour (nph) and total duration of bruxism in seconds per hour (sph), over 26 nights, with treatment from night 4 to 23.

A plot of these two variables shows that their progress over the 26 nights is roughly "parallel", indicating that both react in roughly the same way to the treatment.

enter image description here

The filled circles are the three nights pre and three nights post treatment. Due to the scaling the maximum value for both variables fall on the same point (third night).

My question is:

How can I analyse how "parallel" these two "curves" are?

$\endgroup$
  • 3
    $\begingroup$ Please close stats.stackexchange.com/questions/62927/… (even delete it) in order not to leave little messes in your wake. To the point here, what you do you mean "homogeneous" here? $\endgroup$ – Nick Cox Jun 30 '13 at 12:35
  • 2
    $\begingroup$ What is it you are actually trying to do? As far as I know "homogenous" does not apply to continuous data. But what is your research question? $\endgroup$ – Peter Flom Jun 30 '13 at 13:15
  • $\begingroup$ If you water two tomato plants growing side by side on your window sill at the same time with the same amount of water, you'd expect them both to grow equally. You could measure their height or weight or number of leaves (or whatever) and test the resulting distribution for homogeneity. If the curves are heterogeneous, then there is an influence beyond the water you give them. $\endgroup$ – user14650 Jun 30 '13 at 13:17
  • 1
    $\begingroup$ There's no contradiction. You are misled by a practically useless and theoretically worthless typonymy of data. Instead of trying to shoehorn your data into Stephens' classification ("continuous," "categorical," etc), focus on their statistical properties and your analytical objectives. E.g., in knowing the data are derived from counts, we can infer many of their likely statistical properties. However, your analytical objectives are unclear. In a comment you state you are looking for "an influence beyond" some third variable. I would recommend you clarify how this applies to your data. $\endgroup$ – whuber Jun 30 '13 at 13:43
  • 4
    $\begingroup$ I think @NickCox already provided a good answer, given your situation. Just looking at the plot and drawing conclusions is also perfectly fine. You don't need a “test” at all costs, especially if you are confused about what a statistical test can tell you. One thing that might help you understand what you are reading here and elsewhere: From your comments, it seems that you are trying to look at the relationship between two variables or two time series, not two distributions. Better just forget this idea of “comparing the distributions” and read basic material about correlation. $\endgroup$ – Gala Jul 1 '13 at 12:36
3
$\begingroup$

As numerous comments have shown, we are having a hard time understanding what you want here, but it seems to me that

  1. Your variables have different units of measurement, so even in principle it makes no sense to ask whether their distributions are the same or different, except in a very loose sense that they might have similar shape (skewness, kurtosis, etc.).

  2. Neither variable as presented is categorical. Deep down there is a categorical variable, bruxism attack or not, but that does not affect analysis of the data. You have measured rates that could be fractional. That rules out chi-square testing absolutely, quite apart from the point above.

  3. Two simple analyses show that your variables are related, a scatter plot of one against the other and a line plot of both against time. The first suggests a simple correlation or regression. It's possible that looking at logarithmic scales would help. Presumably these are just an illustrative example and you have much more data. If there were zeros in other data, logarithmic scale would be more problematic.

(LATER) Your situation is now clearer. I still advise against talking about this as a problem in comparing distributions. It is not what you are seeking and the terminology is just confusing even to statistically-minded people, as this thread and its predecessor show amply.

There are at least three aspects to an analysis in addition to points stressed earlier.

  1. You have several patients. At some point a serious analysis would have to look at variations between patients as well as means.

  2. You can plot your data as time series. I note that in each case the highest mean is immediately before treatment starts. Is this important? Is it suggestive, e.g. that patients are more stressed in anticipation of treatment? Once treatment starts, there seems to be an initial effect which then fades away and fluctuations return.

  3. The analysis closest to your focus on parallel lines (or not) is, as already stated, some kind of correlation or regression, but the time series structure would be ignored by such a correlation or regression. In examining e.g. proportionality there is a question of which variable, if any, is to be regarded as response (outcome, dependent variable).

$\endgroup$
  • $\begingroup$ Thank you. ad (1) Each day, two plants recieve 1 l water each (baseline). Each day they grow 1 cm in height and 2 leaves. Now we vary the amount of water per day and measure height and leaves. Of course the units (cm, n of leaves) are different, but obviously it makes total sense to ask, wether their distributions are the same. ad (2) The numbers given are means over 23 patients. The data of the individual patients had integers (whole numbers). ad (3) This is the whole data there is (after calculating means). It is not an example but real data from a study (not mine). $\endgroup$ – user14650 Jul 1 '13 at 10:06
  • $\begingroup$ My question relates to your no. 3: How related are the lines? Can it be said that they are theoretically the same (i.e. they would be the same if we measured the whole population) and just differ due to random sampling (and a small sample at that)? Or are they theoretically different and their seeming similarity is just an accident? -- I feel like statisticians (you and my professor) and non-statisticians (me) have world views so radically different, that communication is virtually impossible. :-) $\endgroup$ – user14650 Jul 1 '13 at 10:13
  • 3
    $\begingroup$ I've already answered your last comment by pointing you to correlation and regression. FWIW, I am not a statistician, but a geographer. I learned what statistics I know by reading books and analysing data. So your assumption is inaccurate. Also, please stop running your analogy of tomato plants; your thread is confusing enough already. $\endgroup$ – Nick Cox Jul 1 '13 at 11:04
  • 3
    $\begingroup$ It makes "total sense to say w[h]ether their distributions are the same". I disagree and have already explained why. The fact that the data are means is completely new to us. You can plot the means and correlate them, but I don't think any serious analysis is possible without considering variations between patients. In all good faith, I have to recommend finding a statistical consultant or collaborator. If you want better advice from us, you may need to put the really important information you are now providing for the first time upfront in a new question. $\endgroup$ – Nick Cox Jul 1 '13 at 11:11
  • 1
    $\begingroup$ More added to answer. $\endgroup$ – Nick Cox Jul 1 '13 at 12:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy