2-dim. array for plot ?!

34 views
Skip to first unread message

loo...@gmail.com

unread,
Nov 13, 2023, 5:20:42 AM11/13/23
to dislin-users
Hi,

I have two 2-dimensional arrays for calculating data ...
e.g.
double xdata [7,24]
double ydata [7,24]

Then I want to plot a part of it, intuitvly/naivly something like that:
plot xdata[0,*], ydata[0,*] or
plot xdata[0,r:s], ydata[0,r:s]

but I always get the message:
 >>>> Parameters in PLOT must be floatingpoint arrays in record 42 (sundial2.gcl)

Isn't e.g. xdata[0,*] just an array ?!

Greetings
Otto

loo...@gmail.com

unread,
Nov 13, 2023, 5:31:13 AM11/13/23
to dislin-users
I forgot to mention, it's about a GCL script in version 11.5

Helmut Michels

unread,
Nov 14, 2023, 6:19:37 AM11/14/23
to dislin-users
Dear Otto,

as the message said, you need floatingpoint arrays in GCL instead of double arrays.
What about:

    float xdata[7,24]
    float ydata[7,24]

With best regards,

Helmut

loo...@gmail.com schrieb am Montag, 13. November 2023 um 11:20:42 UTC+1:

Loo X

unread,
Nov 15, 2023, 10:58:01 AM11/15/23
to dislin...@googlegroups.com
Thx. Works. I was too much focused on data slicing as on the right type.

--
You received this message because you are subscribed to the Google Groups "dislin-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dislin-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dislin-users/5013b825-6dd3-4678-8751-8fb490b63fb7n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages