help > RE: File name ordering for paired t-test
Apr 27, 2022  01:04 AM | Andrew Zalesky
RE: File name ordering for paired t-test
Hi Polona, 

You raise an important point. Alphanumeric sorting can be counter intuitive. 

My understanding is that upper case (capitals) occur before lower case in alphanumeric order. Therefore, the PAT subjects should indeed be loaded in first. 

It avoid confusion, consider loading a mat file that comprises a three-dimensional matrix (nodes x nodes x subjects). in this way, we can be sure that the subjects are ordered in the desired order. Alternatively, it might be helpful to avoid using upper case letters in the file naming convention. 

We will consider adding a file order checker in future versions. 

best wishes, 
Andrew

Originally posted by Polona Pozeg:
Dear Andrew and other NBS users,

I would like to follow up on this topic in hope that this information will be useful for others as well.
I've recently discovered an error in my NBS analyses due to the order of how the matrices were read in, which gave me a big headache.

To detail the issue, my subject files were named as followed:
sub-ctrl001
sub-ctrl002
sub-ctrl00n
sub-PAT001
sub-PAT002
sub-PAT00n

Although the file explorer window within the NBS tool displayed the files in an alphanumerical order i.e., the ctrl subjects before the PAT subjects as listed above, I later found out that the PAT subjects were actually loaded first.
So apparently the alphanumerical sorting rules differ (i.e., the capitals come first or not) between how they are displayed in the NBS gui and how they are actually loaded later on.
So a warning for the user to check the nbs.GLM.y structure or even better, some sort of a design matrix review option (as in SPM) to check the order of loaded files would be a very helpful feature to avoid this in the future.

Best
Polona

Threaded View

TitleAuthorDate
Matt Sutterer May 27, 2016
Andrew Zalesky May 27, 2016
Polona Pozeg Apr 26, 2022
RE: File name ordering for paired t-test
Andrew Zalesky Apr 27, 2022
Sean Ma Oct 25, 2017
Andrew Zalesky Oct 26, 2017
Sean Ma Oct 27, 2017