Thanks, it is exactly the function that I needed.
--
View this message in context:
http://r.789695.n4.nabble.com/Find-interval-between-numbers-in-list-or-vector-tp4376115p4378473.html
Sent from the R help mailing list archive at Nabble.com.
__
R-help@r
Have a look at function diff(), e.g.,
diff(c(1,4,10,30))
I hope it helps.
Best,
Dimitris
On 2/10/2012 1:33 PM, alend wrote:
hi,
I have a vector as follow:
myVec = c(1,4,10,30)
How can I get a vector that show the interval of the numbers.
I need to get this result:
distance
2 matches
Mail list logo