Skip to content

Decimal number

5 messages · Eloi Mercier, hafida, arun

#
Hello,

? beta0<-64.90614
?beta1<-17.7025
?herbeta<-c(beta0,beta1)
?herbeta
[1] 64.90614 17.70250

So, here you have "herbeta" (or is it simply "beta") assigned to the vector containing values of beta0 and beta1.? 
Your statement
"I want to get the number of beta and beta with the full part after the
comma" 
is confusing.
A.K.





----- Original Message -----
From: hafida <hafida-06 at hotmail.fr>
To: r-help at r-project.org
Cc: 
Sent: Tuesday, August 7, 2012 4:37 PM
Subject: Re: [R] Decimal number

hello arun
comma


hafida



--
View this message in context: http://r.789695.n4.nabble.com/Decimal-number-tp4639428p4639452.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
#
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_beta instead).

Cheers,

Eloi

########
Salut Hafida,

je ne comprend pas la question. Peux tu d?tailler stp ?
Si c'est pour afficher les valeurs compl?tes de beta0 et beta1 alors 
l'exemple ci-dessus devrait faire l'affaire.

Autrement, R n'autorise pas la pr?sence d'espace dans le nom des variables.

Cordialement,

Eloi
On 12-08-07 01:37 PM, hafida wrote:

  
    
#
Hi,

You are right, R doesn't allow white space within variable.? 


?beta0 = 64.90614
? beta1 = 17.7025
?her beta<-c(beta0,beta1)
#Error: unexpected symbol in "her beta"
?"her beta"<-c(beta0,beta1)
?"her beta"
#[1] "her beta"

#But, this will get the results:
?`her beta`<-c(beta0,beta1)

?`her beta`
#[1] 64.90614 17.70250
A.K.



----- Original Message -----
From: Eloi Mercier <emercier at chibi.ubc.ca>
To: hafida <hafida-06 at hotmail.fr>
Cc: r-help at r-project.org
Sent: Tuesday, August 7, 2012 5:02 PM
Subject: Re: [R] Decimal number

Hi hafida,

I fail to understand the question. Could you elaborate please ?

Is this what you want ?
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_beta instead).

Cheers,

Eloi

########
Salut Hafida,

je ne comprend pas la question. Peux tu d?tailler stp ?
Si c'est pour afficher les valeurs compl?tes de beta0 et beta1 alors 
l'exemple ci-dessus devrait faire l'affaire.

Autrement, R n'autorise pas la pr?sence d'espace dans le nom des variables.

Cordialement,

Eloi
On 12-08-07 01:37 PM, hafida wrote: