gianni lavaredo
2012-May-16 17:06 UTC
[R] how disable the Error massage in read.table() " no lines available in input"
Dear Researchers, I am looking a way to disable the Error massage in read.table() as warn TRUE in readLines(), when the lines are empty Error in read.table(con, header = F, sep = " ", nrow = n) : no lines available in input thanks for all suggestions Gianni [[alternative HTML version deleted]]
Rui Barradas
2012-May-17 11:28 UTC
[R] how disable the Error massage in read.table() " no lines available in input"
Hello, Apparently this is a follow-up from an earlier post. I had answered but a misplaced comma in the subject line started another thread, that you haven't read. My original answer is in http://r.789695.n4.nabble.com/Re-Problem-to-resolve-a-step-for-reading-a-large-TXT-and-split-in-several-file-td4630242.html As for your question, see the error trapping functions help pages. ?try ?tryCatch And, in readLines the correct option would be ok = TRUE, warn = TRUE is about an end of text marker. ?readLines Hope this helps, Rui Barradas Em 17-05-2012 11:00, gianni lavaredo escreveu:> Date: Wed, 16 May 2012 19:06:14 +0200 > From: gianni lavaredo<gianni.lavaredo at gmail.com> > To:r-help at r-project.org > Subject: [R] how disable the Error massage in read.table() " no lines > available in input" > Message-ID: > <CAJ6JbR-H6p9A+hZk-exGYDcPdC__SLBLrM_oRw-=j+DU3YGXJw at mail.gmail.com> > Content-Type: text/plain > > Dear Researchers, > > I am looking a way to disable the Error massage in read.table() as warn > TRUE in readLines(), when the lines are empty > > Error in read.table(con, header = F, sep = " ", nrow = n) : > no lines available in input > > thanks for all suggestions > Gianni > > [[alternative HTML version deleted]] >