**6.7k**wrote:

I have a dataset that consists of repeated RNA-seq samples from a set of individuals at multiple time points. The early time points are all uniform: every individual was sampled at 0, 7, 14, and 28 days. But after that, different individuals were sampled at roughly periodic intervals, but all on different days. An MDS plot of the data indicates that time point effects explain at least the first 2 principal coordinates of the data:

In the MDS plot, each line represents the trajectory of an individual over time, and the points represent each of the samples for that individual. The color represents the range of the first 30 days (i.e. all the synchronized time points) and each time point after that is roughly another month. (POD stands for "post-operation day".) As you can see, the general trend is starting on the left, going right, then up, then slowly drifting left again. There are other experimental factors as well, but modelling them is more straightforward, and they don't show up in PC1 or 2, so I'm just focusing on time point for this question.

Anyway, I mostly care about the early time points (0 through 28), but I still want to include the later time points in my model to improve the variance estimation, as is generally recommended. My problem is that the early time points are more easily modelled as a factor of discrete time points, while the later time points pretty much have to be modelled as a continuous numeric variable, probably using the natural spline basis method. I'd like to avoid having to use the natural spline approach for the entire time point variable, since I want to make specific contrasts between specific early time points, and this is difficult to impossible with a spline basis. So is it valid to split the time variable into two stages like this and model them using different methods? How would I evaluate if such a design is a good fit for the data?

Here is the table of all the samples' individual ID and time point, if you want to look at it: https://dl.dropboxusercontent.com/u/1581949/table.xlsx

**19k**• written 2.5 years ago by Ryan C. Thompson ♦

**6.7k**