Re: [R] I can't get seq to behave how I think it should

2019-01-18 Thread Martin Maechler
Tupper >> Sent: Thursday, January 17, 2019 2:43 PM >> To: POLWART, Calum (COUNTY DURHAM AND DARLINGTON NHS >> FOUNDATION TRUST) >> Cc: r-help@r-project.org >> Subject: Re: [R] I can't get seq to behave how I think it should >>

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread ProfJCNash
> >> >> -Original Message- >> From: PIKAL Petr [mailto:petr.pi...@precheza.cz] >> Sent: 17 January 2019 14:30 >> To: POLWART, Calum (COUNTY DURHAM AND DARLINGTON NHS FOUNDATION TRUST); Ben >> Tupper >> Cc: r-help@r-project.org >> Subjec

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread peter dalgaard
9 and not 1.4! > > > -Original Message- > From: PIKAL Petr [mailto:petr.pi...@precheza.cz] > Sent: 17 January 2019 14:30 > To: POLWART, Calum (COUNTY DURHAM AND DARLINGTON NHS FOUNDATION TRUST); Ben > Tupper > Cc: r-help@r-project.org > Subject: RE: [R] I can't ge

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread Jeff Newmiller
ARLINGTON NHS FOUNDATION TRUST); >Ben Tupper >Cc: r-help@r-project.org >Subject: RE: [R] I can't get seq to behave how I think it should > >Hi > >It is not seq problem, it is floating point numbers representation in >finit precision problem. Ben pointed to it and you could learn ab

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread POLWART, Calum (COUNTY DURHAM AND DARLINGTON NHS FOUNDATION TRUST) via R-help
(COUNTY DURHAM AND DARLINGTON NHS FOUNDATION TRUST); Ben Tupper Cc: r-help@r-project.org Subject: RE: [R] I can't get seq to behave how I think it should Hi It is not seq problem, it is floating point numbers representation in finit precision problem. Ben pointed to it and you could learn

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread PIKAL Petr
) > Sent: Thursday, January 17, 2019 2:56 PM > To: PIKAL Petr ; Ben Tupper > Cc: r-help@r-project.org > Subject: RE: [R] I can't get seq to behave how I think it should > > Thanks guys. > > I've used Petr's method and its working for me. > > If the data had been

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread POLWART, Calum (COUNTY DURHAM AND DARLINGTON NHS FOUNDATION TRUST) via R-help
Ben Tupper; POLWART, Calum (COUNTY DURHAM AND DARLINGTON NHS FOUNDATION TRUST) Cc: r-help@r-project.org Subject: RE: [R] I can't get seq to behave how I think it should Hi Or you could use rounding. which(round(lut, 3)==1.8) [1] 401 Cheers Petr > -Original Message- > From:

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread PIKAL Petr
help@r-project.org > Subject: Re: [R] I can't get seq to behave how I think it should > > Hi, > > This looks like a floating point reality bump - see > > https://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-doesn_0027t-R-think- > these-numbers-are-equal_003f <https://cran.r-p

Re: [R] I can't get seq to behave how I think it should

2019-01-17 Thread Ben Tupper
Hi, This looks like a floating point reality bump - see https://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-doesn_0027t-R-think-these-numbers-are-equal_003f You can use other methods to finding

[R] I can't get seq to behave how I think it should

2019-01-17 Thread POLWART, Calum (COUNTY DURHAM AND DARLINGTON NHS FOUNDATION TRUST) via R-help
I am using seq with the expression seq(1.4, 2.1, by=0.001) to create a sequence of references from 1.4 to 2.1 in 0.001 increments. They appear to be created correctly. They have a related pair of data which for the purposes of this we will call val. I'm interested in the content on the row wi