Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2004

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

Search the Archive

Re: newbie myHead question

  • To: mathgroup at
  • Subject: [mg47031] Re: newbie myHead question
  • From: bobhanlon at (Bob Hanlon)
  • Date: Mon, 22 Mar 2004 05:18:43 -0500 (EST)
  • References: <c3h1jj$bc8$>
  • Sender: owner-wri-mathgroup at



myHead[{a, a, a}, {b, b, b}]

Bob Hanlon

In article <c3h1jj$bc8$1 at>, =?ISO-8859-1?Q?J=E1nos?=
<janos.lobb at> wrote:

<< I have

m = {{a, b}, {a, b}, {a, b}}

When I apply Transpose to it, I will have


{{a, a, a}, {b, b, b}}

The FullForm of it is

List[List[a, a, a], List[b, b, b]]

Now, if I do

n = Apply[myHead, m]

I get

myHead[{a, b}, {a, b}, {a, b}]

If I apply Transpose to it, I get


Transpose[myHead[{a, b}, {a, b}, {a, b}]]

The FullForm of it

Transpose[myHead[List[a, b], List[a, b], List[a, b]]]

which is not that I need.  I need



myHead[List[a, a, a], List[b, b, b]]

What am I missing ?  What should I do to get myHead[{a,a,a},{b,b,b}] ?

  • Prev by Date: Re: FW: Question on Ordering
  • Next by Date: Re: WorldPlot Question
  • Previous by thread: Re: newbie myHead question
  • Next by thread: Re: newbie myHead question