Yes.  Complex numbers plot differently (they are assumed to be x,y pairs)

If you take the real part, using 9&o., it should work.  Better to use norm2.

Henry Rich

On 10/3/2014 7:24 PM, Vijay Lulla wrote:
When I tried it I got the following:

     datatype norm1 3j4 12j5

complex

     datatype norm2 3j4 12j5

floating


Maybe this could be the issue?


On Fri, Oct 3, 2014 at 7:16 PM, bill lam <[email protected]> wrote:

I forwarded this to J forum because I have no real knowledge of plot.
---------- Forwarded message ----------
From: "Andrey Paramonov" <[email protected]>
Date: Oct 4, 2014 7:07 AM
Subject: Plotting magnitudes of complex numbers in J
To: <[email protected]>
Cc:

Hi Bill,

For some reason my message to [email protected] doesn't go
through, so I thought I can shoot you an email with some strange
behaviour (bug?) I see in the plot function. Here is the snippet that
highlights the problem

    norm1=: %:@:(* +)
    norm2=: |
    norm1 3j4 12j5
5 13
    norm2 3j4 12j5
5 13
    load 'plot'
    plot norm2 3j4 12j5 NB. works
    plot norm1 3j4 12j5 NB. does NOT work

I thought you might find it interesting.

Thank you,
Andrey

P.S. I'm using j64-802.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to