Dear all,

I am trying to perform a longitudinal lme analysis using freesurfer 5.3.0. For qdec tables with many columns the asegstats2table (and similarly aparcstats2table) commands fail with error message:

asegstats2table  --qdec-long ./qdec/long.qdec.table.dat --delimiter space --meas volume    --stats aseg.stats  --tablefile ./measures/lme.aseg.table.txt
SUBJECTS_DIR : /sw/global/applications/freesurfer/5.3.0/x86_64/subjects
Traceback (most recent call last):
  File "/sw/global/applications/freesurfer/5.3.0/x86_64/bin/asegstats2table", line 514, in <module>
    subj_listoftuples = assemble_inputs(options)
  File "/sw/global/applications/freesurfer/5.3.0/x86_64/bin/asegstats2table", line 316, in assemble_inputs
    dialect = csv.Sniffer().sniff(f.read(1024))
  File "/home/dgeisler/env/lib/python2.7/csv.py", line 184, in sniff
    raise Error, "Could not determine delimiter"
_csv.Error: Could not determine delimiter


A solution in my case is to change the line:
    dialect = csv.Sniffer().sniff(f.read(1024))
to:
    dialect = csv.Sniffer().sniff(f.read(2048))

Namely the snifffer needs a larger chunk of file to be able to determine the delimiter, in my case. However I think it would be good if one could give the delimiter of the infile as an option from command line. If  I have correctly understood the --delimiter option available so far is for the output file, which I called  ./measures/lme.aseg.table.txt .


Cheers,
Fabio

Dr. Fabio Bernardoni
wiss. Mitarbeiter
Klinik und Poliklinik für Kinder- und Jugendpsychiatrie und -psychotherapie

Tel. +49 (0)351 458-5245
Fax +49 (0)351 458-7206

Universitätsklinikum Carl Gustav Carus
an der Technischen Universität Dresden
Anstalt des öffentlichen Rechts des Freistaates Sachsen
Fetscherstraße 74, 01307 Dresden
http://www.uniklinikum-dresden.de

Vorstand: Prof. Dr. med. D. M. Albrecht (Sprecher), Wilfried E. B. Winzer
Vorsitzender des Aufsichtsrates: Prof. Dr. med. Peter C. Scriba
USt.-IDNr.: DE 140 135 217, St.-Nr.: 203 145 03113