[R] Number -> Fraction

Gabor Grothendieck ggrothendieck at gmail.com
Thu Sep 13 17:07:31 CEST 2007


Try:

library(MASS)
?fractions


On 9/13/07, Mauro Arnoldi <agharti81 at tiscali.it> wrote:
> Hi everybody!
> I'm new to this list and also to the R program.
>
> I'd like to know if there is a function able to convert results into
> Fractional form like my scientific calculator have. For example:
>
> > 1/3
> [1] 0.3333333
>
> > function_that_return_a_fraction_from_numbers(0.3333333)
> [1] 1/3
>
> Thanks
>
> Mauro
>
> --
>
>
> Man, he is constantly growing
> and when he is bound by a set
> pattern of ideas or way
> of doing things, that's when
> he stops growing
>        -- Bruce Lee
>
> ______________________________________________
> 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.
>



More information about the R-help mailing list