MathGroup Archive 2006

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

Search the Archive

Re: Output Table Format Change

  • To: mathgroup at
  • Subject: [mg66690] Re: Output Table Format Change
  • From: Bill Rowe <readnewsciv at>
  • Date: Sat, 27 May 2006 03:51:46 -0400 (EDT)
  • Sender: owner-wri-mathgroup at

On 5/26/06 at 4:17 AM, mathma18 at (Narasimham) wrote:

>Is there a command   for  removal of  brackets  automatically from
>output ?

Yes, Flatten does this. Flatten accepts a second argument to specify what level of braces should be removed.

>tbl = Table[ N[ {Sin[u+v],Cos[u-v]}],{u,0, Pi,Pi/6},{v,0, Pi,Pi/6}]


>tb is same as tbl from which extra curly brackets {  } are manually
>removed. (tbl output  is deleted here).

It is quite unclear as to what you got when you did a manual removal since you didn't specify which brackets were removed.

Assuming you want a list of {Sin[u+v],Cos[u-v]} pairs in the order they were created, then

tb =Flatten[tbl,1];

should be what you want.

Alternatively, the same thing can be accomplished with Join, i.e.,


However, since

ListPlot[Join@@tbl, PlotJoined->True];

will make a line from the last coordinate pair in a row to the first coordinate pair in the next row, I wonder if

  ListPlot[#, PlotJoined->True]&/@tbl];

is a better choice?
To reply via email subtract one hundred and four

  • Prev by Date: Re: Clearing a symbol known only through a definition
  • Next by Date: Re: scalar field visualization
  • Previous by thread: Re: Output Table Format Change
  • Next by thread: Re: Output Table Format Change