I have a time course experiment that follows 8 treatment groups of 12 fish for 24 hours with observations made at 5 second intervals. Among the measurements made is how far each fish travels (in mm) between observations. The 24 hours are divided into 1 dark period and 1 light period.
Here is a plot of the movements of the 12 individual fish in treatment group H for the first hour of the dark period:
You can see that some fish have long periods of inactivity, some short periods, and some have none during this particular window. I need to combine the data from all 12 fish in the treatment group in such a way as to identify the length and frequency of the rest periods during the entire dark period and the entire light period. I need to do this for each treatment group. Then I need to compare the differences between their rest period lengths and frequencies.
I'm not a stats gal, and I'm completely at sea. The problem resembles sequence alignment to me (my bioinfomatics background), so I'm thinking Hidden Markov models, but this may be way off base. Could anyone suggest a good approach to this problem and perhaps a small example in R?
Thanks!