MathGroup Archive 2011

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

Search the Archive

Re: concatenate matrices?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg118112] Re: concatenate matrices?
  • From: Heike Gramberg <heike.gramberg at gmail.com>
  • Date: Tue, 12 Apr 2011 06:53:23 -0400 (EDT)

There are several ways to achieve this. For example, you could do 

y = Transpose[{Flatten[v1], Flatten[v2]}];

Another option would be

y = Flatten[{v1, v2}, {{2}, {3, 1}}];

which is slightly faster.

Heike.


On 11 Apr 2011, at 12:08, hadi motamedi wrote:

> Dear All
> I have two column matrices named y1 & y2 with dimensions as 448000*1 .
> Can you please let me know how to construct a new matrix say 'y' with
> dimensions 448000*2 such that each column of it equals y1(or y2)?
> Thank you
> 



  • Prev by Date: Re: CDF browser plugin and Wolfram library archive
  • Next by Date: Re: x y coordinates of image pixels for an image outline
  • Previous by thread: Re: concatenate matrices?
  • Next by thread: Re: concatenate matrices?