When I use the GLS estimation to analyse paired data, should I provide own degrees of freedom = number of pairs or leave the default? Let's assume I have a repeated data study with 100 subjects.
Now let's assume I have just pairs.
I want to use the GLS estimation for it. Let's assume the compound symmetry residual structure, so we have here just 1 parameter estimated - the correlation. There should be 100/2=50 pairs (assume no gaps in data), but the GLS uses the number of observations minus 1 parameter = 99.
This looks like a fake replication, but, well, the GLS DOES account for the correlated data, by it's nature, so I guess it's a valid method of analysing such data.
Now, when I repeat the same analysis with a mixed model, I get DF = 50 pairs, which is OK.
OK, now my question. Assuming, that I don't want to play with random effects and just want the marginal GLS model, should I manually set the degrees of freedom to 49? (50 pairs minus 1 correlation estimate), or leave the 99 as it was originally?
Why GLS for just paired data? Because it was only a simplification - I want to analyse more than 2 time points, actually 7. So that's why I want a model-based approach.
 A: S8ppose you are doing a paired t test with fifty pairs, then that amounts to a one-sample t test on the fifty differences.  Suppose that the differences are nearly normally distributed.
Then the t-statistic under $H_0$ $(0$ difference) will have Studen't t distribution with $n - 1 = 50 - 1 = 49$ degrees of freedom.
Specifically, suppose the fifty differences are in the vector d show and summarized below.
summary(d); length(d);  sd(d)
   Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
  2.420   2.838   2.987   2.974   3.076   3.242 
[1] 50         # sample size
[1] 0.1746669  # sample SD

boxplot(d, horizontal=T, col="skyblue2", pch=19)


A normal Q-Q plot shows points mainly along a straight
line (in spite of the moderate boxplot 'outlier', which is not
unusual). With as few as $n = 50$ differences, it is difficult to know for sure whether data are normal, but
for a t test, exact normality is not required. One should not be surprised if relatively few points near the maximum and minimum stray a little from the reference line.
qqnorm(x);  qqline(x, col="blue")


Here is output from a one-sample t test in R of the $n = 50$ differences summarized above. The very small P-value shows a clear rejection of $H_0.$
t.test(d)

        One Sample t-test

data:  d
t = 120.41, df = 49, p-value < 2.2e-16
alternative hypothesis: 
  true mean is not equal to 0
95 percent confidence interval:
 2.924585 3.023865
sample estimates:
mean of x 
  2.974225 

If you were expecting significantly positive
differences d from the start, it might be
appropriate to do a one-sided t test.
For reference, here are Q-Q plots of samples that are clearly
not sampled from normal populations. Too many points stray too far from a straight line.
More specifically, the first plot is for data from a symmetic, heavy tailed population, the second from a uniform distribution (essentially not tails), and the third from a strongly right-skewed distribution with a heavy right tail.
A t test might not do too badly with the middle dataset; the major disasters stem from data with heavy tails in one or both directions.

Note: If you want to look for differences among differences from
more than two time points, then you need to use an ANOVA
model. The usual procedure is to ask first if there
are any differences at all; then if so, to look at
differences over various time periods in a way that
doesn't unduly risk 'false discovery' from repeated
analyses on the same data.
If you have a specific project
of that kind in mind, then you need to be specific what
and how many time periods you have in mind. Then ask a new
new question with the specifics.
