On 11/3/05, Andrew Miner wrote:
> I'm new to maxima, and am having trouble finding out
> how to export data from maxima to a text file.
>
> If I have a matrix, or other set of data how can I
> create a tab delimited text file. I'd like to use it
> to plot data in GRI.
If you have Maxima 5.9.2, try this:
load (numericalio);
write_data (my_matrix, "my_output.txt");
That writes my_matrix with the elements separated by spaces.
write_data (my_matrix, "my_output.txt", 'csv); => separated by commas
write_data (my_matrix, "my_output.txt", 'pipe); => separated by vertical bars
At present there isn't an option to set the separator to a tab.
Let me know if that's necessary and I'll add it.
numericalio has other capabilities.
The file maxima/share/contrib/numericalio/numericalio.lisp has a
comment header which has more information.
numericalio is unfortunately misnamed; it can handle symbols
as well as numbers. I'll probably try to rename it. Sorry for the confusion.
Robert Dodier