Re: [R] fractional part

From: Hans-Peter <gchappi_at_gmail.com>
Date: Thu 28 Sep 2006 - 17:40:11 GMT

2006/9/28, Berton Gunter <gunter.berton@gene.com>:
> ?"%%"

I didn't know that operator, thanks!

But I was not clear, as I was looking more towards a lowlevel function. E.g. "trunc", "floor", "ceiling", ... are defined in names.c and while I currently not fully understand this I thought there could be a similair thing for fraction.

I defined the function "frac <- function(x) abs( x - trunc(x) )" which seems to work well.

Thanks again,
Hans-Peter



R-help@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. Received on Fri Sep 29 03:43:17 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Thu 28 Sep 2006 - 18:30:10 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.