powered by
Reorders the columns of matrix a according to the ordered elements of array s
a
s
find_sub(a,s,j,c,st)
Returns a submatrix of matrix a which consits of columns determined by the input array s
A j x N matrix, containing all possible subsets (N overall) of the size j of predictors' indices.
j
array of numbers of the size N
number of rows in a
array of all indices of the predictors
a subset of predictors to be always included into a predictive model
#all two-element subsets of 1:3 a<-combn(3,2) s<-c(3,2,3) find_sub(a,s,2,1:3)
Run the code above in your browser using DataLab