Probably a problem in your setting or envirenment or print function
Here is what I get
> x1<-64.90
> x2<-17.7025
> c(x1,x2)
[1] 64.9000 17.7025
> x<-c(x1,x2)
> x
[1] 64.9000 17.7025
>
Regards
Petr
>
> HI
>
> >i have a little problem please help me to solve it
>
> >this is the code in R:
>
>
get the results:
`her beta`<-c(beta0,beta1)
`her beta`
#[1] 64.90614 17.70250
A.K.
- Original Message -
From: Eloi Mercier
To: hafida
Cc: r-help@r-project.org
Sent: Tuesday, August 7, 2012 5:02 PM
Subject: Re: [R] Decimal number
Hi hafida,
I fail to understand the questio
HI
>THANK YOU ALL OF YOU
>THIS PROBLEM IS SOLVED
>THANK YOU
>hafida
--
View this message in context:
http://r.789695.n4.nabble.com/Decimal-number-tp4639428p4639467.html
Sent from the R help mailing list archive at Nabble.com.
__
R-help@r-project.o
and beta with the full part after the
comma"
is confusing.
A.K.
- Original Message -
From: hafida
To: r-help@r-project.org
Cc:
Sent: Tuesday, August 7, 2012 4:37 PM
Subject: Re: [R] Decimal number
hello arun
>her beta can be considered simply as an object.
> when i wro
to get the number of beta and beta with the full part after the
>> comma
>
> thank you
> hafida
>> beta0
> [1] 64.90614
>> beta1
> [1] 17.7025
>> round(beta)
> [1] 17 64
>> floor(beta)
> [1] 17 64
>
>
>> From: michael.weyla...@gmail.com
On Tue, Aug 7, 2012 at 11:47 AM, hafida wrote:
> HI
>
>>i have a little problem please help me to solve it
>
>>this is the code in R:
>
>>> beta0
> [1] 64.90614
>> beta1
> [1] 17.7025
>> beta
> [1] 17 64
>
>>her beta<- c(beta0, beta1)
>
> thank you in advance
> hafida
Are you looking for the roun
Hello Hafida,
So, I guess the decimal number problem is solved.
I'll check on it.
A.K.
From: hafida goual
To: smartpink...@yahoo.com
Sent: Tuesday, August 7, 2012 4:58 PM
Subject: RE: [R] Decimal number
thank you a lot
please can you visite my
Hi hafida,
I fail to understand the question. Could you elaborate please ?
Is this what you want ?
> beta0 = 64.90614
> beta1 = 17.7025
> beta<-c(beta0, beta1)
beta
[1] 64.90614 17.70250
As a side note, please keep in mind that R doesn't allow white space
within variable name (name it her_bet
hello arun
>her beta can be considered simply as an object.
> when i wrote beta
>I want to get the number of beta and beta with the full part after the
comma
hafida
--
View this message in context:
http://r.789695.n4.nabble.com/Decimal-number-tp4639428p4639452.html
Sent from the R help mai
HI
>i have a little problem please help me to solve it
>this is the code in R:
>> beta0
[1] 64.90614
> beta1
[1] 17.7025
> beta
[1] 17 64
>her beta<- c(beta0, beta1)
thank you in advance
hafida
--
View this message in context:
http://r.789695.n4.nabble.com/Decimal-number-tp4639428.html
Se
On Wed, Feb 08, 2012 at 03:12:56PM +0100, Arnaud Gaboury wrote:
> Hello,
>
> I have to deal with numbers with a decimal part as quarter, coming from two
> systems with different way to show decimals. I need to tell R these are in
> fact the same number.
>
> On one side my number are formatted t
] decimal number format as quarter
On Feb 8, 2012, at 15:48 , David Reiner wrote:
> Looks like something priced in eighths; we deal with similar notation for
> bonds and similar instruments.
>
>> x <- c(2.2, 2.4, 2.6, 3.2, 3.4, 3.6)
>> as.integer(x)+10*(x-as.integer(x)
On Wed, Feb 8, 2012 at 9:12 AM, Arnaud Gaboury wrote:
> Hello,
>
> I have to deal with numbers with a decimal part as quarter, coming from two
> systems with different way to show decimals. I need to tell R these are in
> fact the same number.
>
> On one side my number are formatted this way : 2
On Feb 8, 2012, at 15:48 , David Reiner wrote:
> Looks like something priced in eighths; we deal with similar notation for
> bonds and similar instruments.
>
>> x <- c(2.2, 2.4, 2.6, 3.2, 3.4, 3.6)
>> as.integer(x)+10*(x-as.integer(x))/8
> [1] 2.25 2.50 2.75 3.25 3.50 3.75
>
> Adjust the 10 an
-
From: David Reiner [mailto:david.rei...@xrtrading.com]
Sent: mercredi 8 février 2012 15:48
To: Arnaud Gaboury; jim holtman
Cc: r-help@r-project.org
Subject: RE: [R] decimal number format as quarter
Looks like something priced in eighths; we deal with similar notation for bonds
and similar
Message-
> From: jim holtman [mailto:jholt...@gmail.com]
> Sent: mercredi 8 février 2012 15:36
> To: Arnaud Gaboury
> Cc: r-help@r-project.org
> Subject: Re: [R] decimal number format as quarter
>
> will this do it for you:
>
>> x <- c(2.2, 2.4, 2.6, 3.2, 3.4
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On
Behalf Of Arnaud Gaboury
Sent: Wednesday, February 08, 2012 8:45 AM
To: jim holtman
Cc: r-help@r-project.org
Subject: Re: [R] decimal number format as quarter
TY Jim,
It do the trick.
I was tryin
On Feb 8, 2012, at 9:12 AM, Arnaud Gaboury wrote:
Hello,
I have to deal with numbers with a decimal part as quarter, coming
from two systems with different way to show decimals. I need to tell
R these are in fact the same number.
On one side my number are formatted this way : 2.2 , 2.4 a
Subject: Re: [R] decimal number format as quarter
will this do it for you:
> x <- c(2.2, 2.4, 2.6, 3.2, 3.4, 3.6)
> # get integer part
> x.i <- as.integer(x)
> # get fractional part
> x.f <- (x * 10) %% 10
> # new result
> result <- x.i + ifelse(x.f
will this do it for you:
> x <- c(2.2, 2.4, 2.6, 3.2, 3.4, 3.6)
> # get integer part
> x.i <- as.integer(x)
> # get fractional part
> x.f <- (x * 10) %% 10
> # new result
> result <- x.i + ifelse(x.f == 2
+ , .25
+ , ifelse(x.f == 4
+
Hello,
I have to deal with numbers with a decimal part as quarter, coming from two
systems with different way to show decimals. I need to tell R these are in fact
the same number.
On one side my number are formatted this way : 2.2 , 2.4 and 2.6. On the other
side, I have 2.25, 2.50 and 2.75.
A
21 matches
Mail list logo