Manipulate text files
Posted by
lechristophe on
Nov 15, 2013; 10:37pm
URL: http://imagej.273.s1.nabble.com/Manipulate-text-files-tp5005575.html
Hi,
I want to manipulate big tab-delimited text files, like extract specific
columns, reorder them, generate new columns by simple calculations on
existing columns, and generate a new text file from this.This is typically
to translate data/results files obtained from various software, from one
format to another.
What is the most efficient to do this in IJ Javascript? For the moment I
import the whole text file as a string, make an array from it (parsing the
numerical values), manipulate the array, convert it back to a big string,
and save it. But for text files with 10^5-10^6 lines it takes ages to
process. Is it possible to read/write line by line from the input file to
the output file using IJ Javascript?
Alternatively, I'd be open to suggestions for using other than IJ
Javascript to do that, as it is not really image processing.
Thanks for your help,
Christophe
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html