tk/Inhouse_lmm: fixed cholevsky decomposition and design matrix calculation
potrf function in lapack updates the lower or upper part of its argument but leaves the rest "as is". there was a serious bug in the calculation of the design matrix (confusion between indices of row and columns), but also in principle it was incorrect, because it was not full rank. One hot encoding means the related columns sum to 1, that is the sum is equal to the offset column. Finally when computing the degrees of freedom for the F-distribution there were a few confusions.
Showing with 36 additions and 24 deletions