I have a gene expression dataset including 520 sample and around 20000 genes. I would like to build a prediction model to detect genes that can predict my outcome. My outcome is the expression level of my interest gene. So, I am advised to do this using the stability selection from package stabs and glmnet package in R
I am running an stability selection using stabsel() in R. However, I get constantly error as : "Error in res[[1]]: subscripts out of bounds". Here is an example of part of codes:
this is the summary of my outcome:
median: -0.05 Mean: -0.039 1st QU:-0.114 3rd QU:0.018 Min:-0.49 Max: 0.94
library(stabs)
library(glmnet)
dat = stabsel(x = d[,-800]), y = y, sampling.type = "SS", fit.fun = glmnet.lasso, cutoff = 0.6, q = 60)