[R] problem with number formation

Berend Hasselman bhh at xs4all.nl
Mon Jan 4 17:37:52 CET 2010



dvkirankumar wrote:
> 
> Hi all,
> this is kiran
> I got one problem with formating a number
> that is
> 
> if I have a number like ------->"2.33"
> that one ihave to convert to ------>"2.33000"
> 

?sprintf

Example:

a <- 2.33
sprintf("%.5f", a)

Berend

-- 
View this message in context: http://n4.nabble.com/problem-with-number-formation-tp998291p998370.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list