How i resolve write.table col.names needs specification error

35 Views Asked by At

I am running a code in R Shiny app and getting an error

Warning: Error in write.table: invalid 'col.names' specification
  1: runApp

I dont know how to solve it. I tried many things.

The write.table is mentioned in the code several times as

write.table(annot.df$UniProt, file='uniprot.txt', quote=FALSE, sep='\t', row.names=FALSE, col.names=FALSE)
    accannot.df <- read.table('uniprot.txt', quote='', sep='\t')
write.table(bm.cnames, file='pData.txt', col.names='Treatment', row.names=FALSE, quote=FALSE, sep='\t')
write.table(annot.df$UniProt, file='uniprot.txt', quote=FALSE, sep='\t', row.names=FALSE, col.names=FALSE)
    accannot.df <- read.table('uniprot.txt', quote='', sep='\t')
write.table(bm.cnames, file='pData.txt', col.names='Treatment', row.names=FALSE, quote=FALSE, sep='\t')
write.table(deAcc, file='normalizedMatrix.txt', quote=FALSE, sep='\t', row.names=FALSE, col.names=FALSE)

So i dont know which is creating a problem and how to resolve it. Any suggestions

I am expecting a correction in the code

0

There are 0 best solutions below