Iterating over a sparse vector Consider the following vector: idx1 <- c(2L, 0L, 4L, 0L, 7L)A sparse representation of this vector will tell that at entries 1,3,5 (or at entries 0,2,4 if we are 0-based) we will find the values 2,4,7. Using Eigen via RcppEigen we can obtain the coercion with .sparseView(). We can iterate over all elements (including the zeros) in a sparse vector...