MathGroup Archive 2010

[Date Index] [Thread Index] [Author Index]

Search the Archive

Exporting a List of Tables with different Lengths to a tabulator


I am trying to export some data I imported and then manipulated with 
mathematica. I have a List of several Tables, i.e.

ListA={TableA, TableB, TableC, ...}

A typical Table looks like this:


The Tables in ListA all have the same number of columns but differing 
number of rows.  Now, I want to export these Tables into one tabulator 
separated file with the same structure, i.e. line N in the output file 
should contain the elements in row N of each Table, or in other words I 
want the following:

TableA[[1,1]]	TableA[[1,2]]	TableB[[1,1]]	TableB[[1,2]]	...
TableA[[2,1]]	TableA[[2,2]]	TableB[[2,1]]	TableB[[2,2]]	...
...		...		...		...
TableA[[M-1,1]]	TableA[[M-1,2]]	TableB[[P,1]]	TableB[[P,2]]	...
TableA[[M,1]]	TableA[[M,2]]					...

Here I chose (as an example), Length[TableA]=M and Length[TableB]=P with 

I tried it with Export["myfile.dat", ListA] but it does not produce the 
desired output, instead it yields:

{TableA[[1,1]],TableA[[1,2]]}	{TableA[[2,1]],TableA[[2,2]]}	...
{TableB[[1,1]],TableB[[1,2]]}	{TableB[[2,1]],TableB[[2,2]]}	...
...				...

(In the above, TableX[[i,j]] represents a number in the corresponding 
element of a table, and not the text "TableX[[i,j]]"... ;) )

Ok, I hope I explained the problem sufficiently. Probably there is a 
simple solution but I just don't see it.

Please help! Thanks!


  • Prev by Date: Re: Question Re PolarPlot Curve Printouts from Mathematica
  • Next by Date: Re: Customizing Manipulate's Autorun
  • Previous by thread: Re: Customizing Manipulate's Autorun
  • Next by thread: Re: Exporting a List of Tables with different Lengths to a tabulator