X-Received: by 2002:a24:9d4a:: with SMTP id f71mr353206itd.33.1552323446644; Mon, 11 Mar 2019 09:57:26 -0700 (PDT) X-Received: by 2002:a05:6830:43:: with SMTP id d3mr91040otp.104.1552323446370; Mon, 11 Mar 2019 09:57:26 -0700 (PDT) Path: csiph.com!weretis.net!feeder6.news.weretis.net!feeder.usenetexpress.com!feeder-in1.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!82no6182itk.0!news-out.google.com!d79ni30itc.0!nntp.google.com!y22no17626ita.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.graphics.apps.gnuplot Date: Mon, 11 Mar 2019 09:57:26 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=2600:1700:caf0:7080:cc5e:7f85:9ae6:1a21; posting-account=eyyzsAoAAAASi1zeqj5JlSdSkG2kEXJt NNTP-Posting-Host: 2600:1700:caf0:7080:cc5e:7f85:9ae6:1a21 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Taking the modulo of column data From: galaxy3xyz@gmail.com Injection-Date: Mon, 11 Mar 2019 16:57:26 +0000 Content-Type: text/plain; charset="UTF-8" Lines: 34 Xref: csiph.com comp.graphics.apps.gnuplot:4166 On Monday, March 11, 2019 at 12:56:21 PM UTC-4, galax...@gmail.com wrote: > On Tuesday, November 12, 2002 at 12:55:38 PM UTC-5, Gert wrote: > > > I don't think so. You did overlook the actual gnuplot documentation, > > > though. To be more precise: "help expression", which says: > > > > > > Note that gnuplot uses both "real" and "integer" arithmetic, like FORTRAN and > > > C. Integers are entered as "1", "-10", etc; reals as "1.0", "-10.0", "1e1", > > > 3.5e-1, etc. The most important difference between the two forms is in > > > division: division of integers truncates: 5/2 = 2; division of reals does > > > not: 5.0/2.0 = 2.5. In mixed expressions, integers are "promoted" to reals > > > before evaluation: 5/2e0 = 2.5. The result of division of a negative integer > > > by a positive one may vary among compilers. Try a test like "print -5/2" to > > > determine if your system chooses -2 or -3 as the answer. > > > > > > This explains why the problem occurs in the first place. > > > > Well, actually, I did read this part of the documentation. So I understood > > the nature of the problem. But the documentation didn't mention anything > > about the possibility to perform casting. > > > > Thanks anyway for pointing me out. > > > > Greetings, > > > > Gert > > This does not work in you use: > > set datafile separator "," > > for comma separated data (CSV) > > This must be a bug right? "if" you use: