Why Matlab give me the error that "the between-subjects design must have full column rank"?
Mostra commenti meno recenti
Hi everyone, here's the problem. I want to analize datas about glycemic values in 10 days for 4 conditions with the test "ranova". I have created a matrix "condition" [10x4], then a cell array [10x1] "timing" with moments of data collection, a table t=table(timing,condition(:,1),condition(:,2),condition(:,3),condition(:,4),'VariableNames',{'timing','all_1','all_2','all_3','ctrl'}), and then a table [4x1] Meas=([1 2 3 4]','VariableNames',{'Measurements'}). When I try to do the function rm=fitrm(t,'all_1-ctrl~timing','WithinDesign',Meas) Matlab gives me the error that the between-subjects design must have full column rank and I can't find the reason why is that. Can you help me please?
1 Commento
Risposte (1)
Debadipto
il 18 Dic 2024
0 voti
The column rank error likely occurs because of the "timing" variable. This can happen if "timing" does not represent independent levels or lacks sufficient variability to maintain a full column rank. For example, if "timing" contains identical values (e.g., 'Day 1' for all rows), it eliminates any variability in the between-subjects factor, making 'timing" collinear and causing a rank deficiency. Ensure that "timing" accurately represents the moments of data collection, avoiding duplicate or constant values that could result in a singular matrix in the design.
Categorie
Scopri di più su Logical in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!