Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.graphics.apps.gnuplot > #3673
| From | Ethan A Merritt <sfeam@users.sourceforge.net> |
|---|---|
| Newsgroups | comp.graphics.apps.gnuplot |
| Subject | Re: Using arrays |
| Date | 2017-06-05 09:41 -0700 |
| Organization | gnuplot development |
| Message-ID | <oh41ds$ttm$1@dont-email.me> (permalink) |
| References | <epgtapF1peqU1@mid.individual.net> <oh08o7$90q$1@dont-email.me> |
Ethan A Merritt wrote:
> If you really want to recover the original data after packing into a set
> of complex values the plot command would have to be something like
>
> plot plt using (real($2)):(imag($2))
>
> That doesn't work either (might be an actual bug lurking there) but at
> least it tries to unpack the original 2 real values from a single
> complex value. A variant that does work is
>
> plot sample [i=1:7:1] '+' using (real(plt[i])):(imag(plt[i]))
>
> That variant is a tour-de-force of new syntax items but I don't see
> anything gained over using the original data format.
In case anyone finds this thread while looking for guidance on
handling complex values...
I later realized that a simpler way to do this is
plot plt using (real(plt[$1])) : (imag(plt[$1]))
Back to comp.graphics.apps.gnuplot | Previous | Next — Previous in thread | Find similar
Using arrays John Edwards <johned0@gmail.com> - 2017-06-03 23:59 +0100
Re: Using arrays Ethan A Merritt <EAMerritt@gmail.com> - 2017-06-03 23:22 -0700
Re: Using arrays John Edwards <johned0@gmail.com> - 2017-06-04 09:30 +0100
Re: Using arrays Ethan A Merritt <sfeam@users.sourceforge.net> - 2017-06-05 09:41 -0700
csiph-web