This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How to aviod auto wrap in the .txt output of long rbind list?

The .txt output should occupies 4 lines (including header), however, each long line was seperated into several lines. So, how shold I do to avoid the long line seperation? fig1 is the output in Rstudio enter image description here

fig2 is the .txt output opened by notepad++ enter image description here

the code is the following:

upgene_list<-list(rownames(DEG[DEG$change =='UP',]))

downgene_list<-list(rownames(DEG[DEG$change =='DOWN',]))

normalgene_list<-list(rownames(DEG[DEG$change =='NOT',]))

geneupdown_list<-rbind(upgene_list,downgene_list,normalgene_list)

write.table(cbind(rownames(geneupdown_list),geneupdown_list),paste0("./", my_id, "_geneupdown.txt"),sep="\t",row.names= F,col.names=T)
geo r deseq2

Minimise your example, and provide expected output. I'd guess before writing it out, you would need paste(myVector, collapse = ",").

0 answers

No answers yet.

Log in to answer this question.