[R] modular in R
Liaw, Andy
andy_liaw at merck.com
Wed Jan 26 01:31:07 CET 2005
> From: Cuichang Zhao
>
> hello,
> i wonder what command should i used in R to do the modular.
> right now i have a vector v <- c(3, 4, 5, 6), but i have
> tried v%2 or v mod 2 or mod(v, 2) or modular(v, 2), and none
> of these works.
It's `%%', as in v %% 2.
> Also, how can i find more function command online, i have to
> search in the mailing list questions, but it is not enough,
> is that a better website i can search more about R online.
help.search("modulo") points you to the basic arithmetic operators in base,
where %% is documented. You might also want to use
http://search.r-project.org/. In the next version of R you can use
RSiteSearch().
Andy
> Thank you so much
>
> Best Wishes
>
>
> C-Ming
>
> Jan 25, 2005
>
>
> ---------------------------------
>
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> 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
>
>
More information about the R-help
mailing list