Question: in R or r studio Write a function called sum_subsequences with arguments: - x : a numeric vector of any length greater than zero. -
in R or r studio
Write a function called sum_subsequences with arguments: - x : a numeric vector of any length greater than zero. - gap: a non-negative integer vector of length one. The function should return a numeric vector of length one that calculates the sum of the subsequence staring from the first term and adding every gap terms. vec=c(1:10)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
