[R] percentage in R

Christoph Heibl christoph.heibl at gmx.net
Thu Jun 21 23:02:29 CEST 2007


Hi,

do you want to display the proportion as a character string? This  
would be simple:

 > a <- 0.25
 > aa <- paste(a*100, "%", sep="")
 > aa
[1] "25%"

Cheers,
Christoph


On 21.06.2007, at 22:45, genomenet at gmail.com wrote:

> Hi There,
>
> How to display a number in the formation of percentage?
>
> For example, a=0.25, how to display 25%?
>
> Thank you very much.
>
> Van
>
> ______________________________________________
> R-help at stat.math.ethz.ch 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.



More information about the R-help mailing list