set2List {XNAString} | R Documentation |
Define method to save XNAStringSet object as a list of XNAString objects
set2List(obj) ## S4 method for signature 'XNAStringSet' set2List(obj)
obj |
XNAStringSet object |
list of XNAString objects
my_dic <- data.table::data.table(type = c(rep('base',3), rep('sugar',2), rep('backbone',3)), symbol = c('G', 'E', 'A', 'F', 'O', 'S', 'B', 'X')) obj2 <- XNAString(name = 'b', base = 'GGE', sugar = 'FFO', dictionary = my_dic) obj3 <- XNAString(name = 'b', base = c('GGE','EEE'), sugar = c('FFO', 'OOO'), dictionary = my_dic) XNAStringSetObj <- XNAStringSet(objects=list(obj2, obj3)) set2List(XNAStringSetObj)