Patients have several pain scores before and after medication treatment. Would like to apply a longitudinal or time series model to compare slopes before and after and evaluate the medication effect on pain reduction.
Hello David. I suggest you look at multilevel modeling, with occasions clustered within individuals. Singer & Willett's book Applied Longitudinal Data Analysis is very good. See the link below for examples of how to estimate the models they describe in the book using several different popular stats packages. HTH.
ႈIn SPSS, there is a function for analysis of repeated measures data. You can get information about longitudinal change and it's significance. You can also adjust covariates and appropriate graphical presentation.
Basically, as the colleagues already indicated, you have a repeated measures design, with several time points of pain ratings during medication and several time points of pain ratings during a washout phase where no med was given.
VAS(Pain) = Time (1..6) x Phase (1..2) + Z(Vpn) + e
This corresponds to a linear mixed model, with the fixed factors on the left and Subj as a random factor. You see I split your complete time series (assumed 12 data points) in two halves, phase 1 introducing meds, phase 2 washout. This allows testing between the two time spans, looking like a tent function:
+ +
+ +
+ +
As we see the main effect of phase would probably end up non sig.if we look at the average values. But there are linear trends in both phases, yielding a sig. trend interaction, calculated for instance with orthogonal polynomials for linear, quadratic, cubic ... trends.
Finally, you could simply compare the individual slopes of all persons in the two phases and simply test which slopes are steeper (holds for equidistant time points). This can be done with quite conventional statistics if the linear mixed model formulation seems too complicated. Hope that helps more than it irritates.
doe all of the other collegues stated RMANOVA is the most appropriate mehod to invastigate the change of VAS over time, but you need to consider that in pain, there is a great heterogenity and the dispersion is mostly not normal, so either a log\rank transformation is needed prior to using RMANOVA, or to use a Friedman Chi-square test, followed by a post hoc test of your choosing
I agree that you have a repeated measures design. Probably also the best model will be the multilevel. I think the Federico Piccioni suggestion is more suitable (regression) for predict pain during the time.