Re: [R] ifelse question (I'm not sure why this is working)...

2013-09-10 Thread David Winsemius
On Sep 10, 2013, at 12:40 PM, Jonathan Greenberg wrote: R-helpers: One of my intrepid students came up with a solution to a problem where they need to write a function that takes a vector x and a scalar d, and return the indices of the vector x where x %% d is equal to 0 (x is evenly

Re: [R] ifelse question (I'm not sure why this is working)...

2013-09-10 Thread Jim Lemon
On 09/11/2013 05:40 AM, Jonathan Greenberg wrote: R-helpers: One of my intrepid students came up with a solution to a problem where they need to write a function that takes a vector x and a scalar d, and return the indices of the vector x where x %% d is equal to 0 (x is evenly divisible by d).

[R] ifelse question (I'm not sure why this is working)...

2013-09-10 Thread Jonathan Greenberg
R-helpers: One of my intrepid students came up with a solution to a problem where they need to write a function that takes a vector x and a scalar d, and return the indices of the vector x where x %% d is equal to 0 (x is evenly divisible by d). I thought I had a good handle on the potential

Re: [R] ifelse question (I'm not sure why this is working)...

2013-09-10 Thread William Dunlap
] On Behalf Of Jonathan Greenberg Sent: Tuesday, September 10, 2013 12:40 PM To: r-help Subject: [R] ifelse question (I'm not sure why this is working)... R-helpers: One of my intrepid students came up with a solution to a problem where they need to write a function that takes a vector x