-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 30/03/11 10:59, Tal Galili wrote:
> Hello Rainer and Fernando,
>
> Actually, I think this function should involve the which.max (not max):
Right - was not awarw of which.max - I would have used which(max(...)) -
which.max is much more elegant.
T
Hello Rainer and Fernando,
Actually, I think this function should involve the which.max (not max):
Here is a tiny function to perform this (with smarter handeling of multiple
modes and giving proper warning in such cases)
The.mode <- function(x, show_all_modes = F)
{
x_freq <- table(x)
mode_loc
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 30/03/11 02:47, Fernando Marmolejo Ramos wrote:
> Dear R users
>
> I?m aware that the package ?modest? is useful to find the mode in an array.
>
> However, I?d like to know if someone has translated the ?mode? function
> built-in
> in MATLAB into
3 matches
Mail list logo