But be careful if your number does not contain only 0:

> sprintf("%E00", pi*1000)
[1] "3.141593E+0300"
> sprintf("%E", pi*1000)
[1] "3.141593E+03"


On Mon, Jun 9, 2008 at 12:42 PM, Paulo Cardoso <pecardoso@netcabo.pt> wrote:

> Yes works,
>
> Thank you Henrique.
>
> I'm so basic with R!
>
> Paulo
>
>
>
> From: Henrique Dallazuanna [mailto:wwwhsd@gmail.com]
> Sent: segunda-feira, 9 de Junho de 2008 17:37
> To: Paulo Cardoso
> Cc: r-help@r-project.org
> Subject: Re: [R] sprintf()
>
>
>
> Try:
>
> sprintf("%E00", pi)
>
> On Mon, Jun 9, 2008 at 1:28 PM, Paulo Cardoso <pecardoso@netcabo.pt>
> wrote:
>
> Hi,
>
> I'm not being able to represent the result of sprintf("%E", pi)
> [1] "3.141593E+00"
>
> Into this:
> "3.141593E+0000"
>
> Thanks in advance
>
> Paulo
>
> ______________________________________________
> R-help@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<http://www.r-project.org/posting-guide.html>
> and provide commented, minimal, self-contained, reproducible code.
>
>
>
>
> --
> Henrique Dallazuanna
> Curitiba-Paraná-Brasil
> 25° 25' 40" S 49° 16' 22" O
>
> No virus found in this incoming message.
> Checked by AVG.
>
> 11:17
>
>
>        [[alternative HTML version deleted]]
>
>
> ______________________________________________
> R-help@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<http://www.r-project.org/posting-guide.html>
> and provide commented, minimal, self-contained, reproducible code.
>
>


-- 
Jim Holtman
Cincinnati, OH
+1 513 646 9390

What is the problem you are trying to solve?

	[[alternative HTML version deleted]]

