Object in R
Factor can be used for sequence data.

From sequence characters
seq <- c("A", "C", "C", "T", "G") seq.factor <- factor(seq, levels=c("A", "G", "T", "C") From numbers to sequences > seq.num <- c(1,2,3,1,1,3,2,1,4,1,3,2,1) > seq.num.factor <- factor(seq.num, levels=c(1,2,3,4), labels=c("A","G","T","C") )

Object in R Factor can be used for sequ …
Tagged on:     

Leave a Reply

Your email address will not be published. Required fields are marked *