3
$\begingroup$

I ran a test to see if a treatment had an effect. Treatment started in 2011 on week 16. Normally, we would take difference of the average percent change from the pre group vs the average percent change of the post group. This gives us a sense of what kind of percent change we would expect to see.

   week 2010    2011    type
    1   3998    3934    pre
    2   3865    3775    pre
    3   3960    3872    pre
    4   3915    3820    pre
    5   4145    4057    pre
    6   4298    4213    pre
    7   4399    4313    pre
    8   4341    4225    pre
    9   4416    4318    pre
    10  4465    4376    pre
    11  4471    4438    pre
    12  4591    4566    pre
    13  4804    4640    none
    14  4865    4796    none
    15  4865    4871    none
    16  4861    4907    post
    17  4922    4982    post
    18  5222    5297    post
    19  5296    5384    post
    20  5434    5520    post
    21  5520    5614    post
    22  5520    5614    post
    23  5521    5618    post

I would like to know if there is a more statistical way to approach this problem.

If you use R then here is the dput to copy and paste,

data = structure(list(week = c(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 
13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23), y2010 = c(3998, 
3865, 3960, 3915, 4145, 4298, 4399, 4341, 4416, 4465, 4471, 4591, 
4804, 4865, 4865, 4861, 4922, 5222, 5296, 5434, 5520, 5520, 5521
), y2011 = c(3934, 3775, 3872, 3820, 4057, 4213, 4313, 4225, 
4318, 4376, 4438, 4566, 4640, 4796, 4871, 4907, 4982, 5297, 5384, 
5520, 5614, 5614, 5618), type = c("pre", "pre", "pre", "pre", 
"pre", "pre", "pre", "pre", "pre", "pre", "pre", "pre", "none", 
"none", "none", "post", "post", "post", "post", "post", "post", 
"post", "post")), .Names = c("week", "y2010", "y2011", "type"
), class = c("tbl_df", "tbl", "data.frame"), row.names = c(NA, 
-23L))
$\endgroup$
1
  • $\begingroup$ Why are there only 23 weeks in the year ? what precisely is "none" supposed to connote ? $\endgroup$
    – IrishStat
    Commented Dec 9, 2017 at 15:57

1 Answer 1

1
$\begingroup$

It would be nice to know what your research problem is and what your hypothesis is. Is this a single subject over time? What are the two columns with header 2010 and 2011? Are those years? You could do a dependent samples t-Test, a repeated measures ANOVA, an Interrupted Time Series ARIMA, a longitudinal hierarchical linear model, autoregressive latent trajectory model...... The method depends most of all on your scientific hypothesis.

$\endgroup$
6
  • $\begingroup$ Thanks for the suggestions. The hypothesis is, does the treatment significantly increase the outcome. $\endgroup$
    – Alex
    Commented Dec 9, 2017 at 20:02
  • $\begingroup$ Is this a single subject? $\endgroup$ Commented Dec 9, 2017 at 20:06
  • $\begingroup$ They are averages from many subjects. $\endgroup$
    – Alex
    Commented Dec 9, 2017 at 22:11
  • 1
    $\begingroup$ I strongly suggest against taking the averages. You are losing valuable information, which would lead to more error. Try setting up your data in a 'wide' format, with each row representing a participant and columns representing observations. Then you can do a repeated measures ANOVA. I think you will find this procedure similar to the procedure you mentioned above. $\endgroup$ Commented Dec 9, 2017 at 22:26
  • 1
    $\begingroup$ Yes, of course. A mixed model would give you more information about the nested structure of the pre/post measurements. But again, it depends on your hypothesis. When you told me your hypothesis, it seemed like you simply wanted to know about the different between pre and post. A longitudinal mixed model would give you a lot more information that might not be worth the effort if you just want to know about pre/post differences. $\endgroup$ Commented Dec 9, 2017 at 23:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.