Skip to content
Back to formatted view

Raw Message

Message-ID: <A3CB44EF-EDD3-4A31-A07A-80D240AA5EE4@gmail.com>
Date: 2012-10-20T11:36:04Z
From: jim holtman
Subject: Error: not 'a real'?
In-Reply-To: <50828953.9040708@gmail.com>

how about supplying the context of the error.  Show the lines in the file where the error occurred.  

Sent from my iPad

On Oct 20, 2012, at 7:21, Brian <zenlines at gmail.com> wrote:

> Hi List,
> 
> when supplying a vector of atomic vector classes to read.table, I get:
> # column classes
> colClasses=c("character", "character","numeric", "numeric", "numeric", "numeric", "numeric", "numeric",
>                                            "numeric", "numeric", "numeric", "numeric")
> # Error:
> Error in scan(file, what, nmax, sep, dec, quote, skip, nlines, na.strings,  (from #2) :
>  scan() expected 'a real', got '894.6'
> 
> How is '894.6' not 'a real [number]'?
> 
> Thanks for the ensuing enlightenment or punishment...
> 
> Best,
> Brian
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.