Unconventional data frame reshaping

I'm trying to reshape table from col1| col2|col3|id v1 | v2 | v3 |1 v2 | v1 | v3 |2 to col1|col2|id v1 | v2 | 1 v2 | v3 | 1 v2 | v1 | 2 v1 | v3 | 2 Basically create pair of following columns for each id. Sorry for not clear title, but ...
more »

| R   2017-10-04 23:10 (5) Answers

Intersection of sorted numpy arrays

I have a list of sorted numpy arrays. What is the most efficient way to compute the sorted intersection of these arrays? In my application, I expect the number of arrays to be less than 10^4, I expect the individual arrays to be of length less than ...
more »

| numpy   2017-10-04 21:10 (1) Answers