Dear List,

I have data on a approximately 100 individuals visiting a a central logging
station over a 1000 times.  I would like to be able to calculate the
distribution of inter-visit time intervals for all possible pairs am stuck
on how to code for this.  Single pairs are not a problem but extending it
has been difficult for me.  So for the toy data below I'd like to calculate
for each 'a' how long until I see 'b' as well as for each 'b', how long
until I see 'a' and so on for all possible pairs (2 triangle of a matrix?)

Thanks for any help, hints, and suggestions.

Grant


toy data:

ind <-  c('a', 'b', 'a', 'c', 'b', 'b', 'c', 'a', 'c')


sec <- c(1, 3, 5, 6, 12, 22, 66, 85, 99)

What I am looking for

ab
2

	[[alternative HTML version deleted]]

