r - working with sequences of different length -
The timestamp is removed from a function XML document I wrote. The timestamp is coupled with events, which are repeated elements of chain elements.
The elements of the series are a variable amount of events, so my work is a data. Gives frames (if the chain has the same length). Normally it gives a more general list and I want to work with the matrix. I have been told that the 'list' is a normal type, but I have difficulty working on normal tasks, but with more specific types No, data like Frame or matrix.
What I need to do with the data at this time is to see what is the most common distance between the timestamp (I hope it will display more than 50%), I do A function is written and rewritten for:
R & gt; MostCommonStep (list (a = cumsum (c (1,3,3,2,3,3,4,3,2,3,3)), b = cumsum (c (2,3,2,3))) ) [1] 3R & gt; Most CommonStep (data. Frames (a = c (2,4,6,8,12,14,18), b = c (12,14,16,18, 22, 24, 28))) [1] 2 R & amp; nbsp;; The most commonest (matrix (c (2,4,6,8,12,14,18,12,14,16,18,22,24,28), 7, 2)) [1] 2
< / Pre>But I would like to see a more "R" confirmation version
data frame lists . Suppose that the distance between time tickets is in vector "x" / list. Data.frame y can get you the mode sort (-table (y [["x"]] [1]
.
Comments
Post a Comment