AFNI Message Board

Dear AFNI users-

We are very pleased to announce that the new AFNI Message Board framework is up! Please join us at:

https://discuss.afni.nimh.nih.gov

Existing user accounts have been migrated, so returning users can login by requesting a password reset. New users can create accounts, as well, through a standard account creation process. Please note that these setup emails might initially go to spam folders (esp. for NIH users!), so please check those locations in the beginning.

The current Message Board discussion threads have been migrated to the new framework. The current Message Board will remain visible, but read-only, for a little while.

Sincerely, AFNI HQ

History of AFNI updates  

|
Colm Connolly
August 21, 2009 05:36AM
Hi Rob,

You may be able to avoid the excel2txt program by exporting the excel sheet as a comma separated value (CSV) file.

You could then set the field separator in awk to extract the columns

#!/bin/bash

for i in 31 32 34 37; do
for j in 1 2 3 4 6 7; do

cat $i.csv | awk 'BEGIN { FS = "," } ; { print $'$j'}' > $i.$j.1D

done
done

If your lines (aka records) do not end in newline characters you can change it by specifying a custom record separator. For example, awk 'BEGIN { FS = "," ; RS="\r" } ; { print $'$j'}' > $i.$j.1D which I think should work, though I've not tried it.

Bye,

Colm.
Subject Author Posted

1dCat use

Rob Hester August 20, 2009 08:01PM

Re: 1dCat use

rick reynolds August 20, 2009 09:27PM

Re: 1dCat use

Rob Hester August 20, 2009 09:39PM

Re: 1dCat use

rick reynolds August 20, 2009 10:37PM

Re: 1dCat use

Rob Hester August 21, 2009 02:14AM

Re: 1dCat use

Rob Hester August 21, 2009 03:17AM

Re: 1dCat use

Colm Connolly August 21, 2009 05:36AM

Re: 1dCat use

Colm Connolly August 21, 2009 05:38AM

Re: 1dCat use

Rob Hester August 21, 2009 07:02AM

Re: 1dCat use

Rob Hester August 26, 2009 12:42AM