Re: [R] data.frame with NA

2013-03-20 Thread David Winsemius
erent than other R objects. -- David. -Original Message- From: Pietro [mailto:freeri...@gmail.com] Sent: Tuesday, March 19, 2013 6:10 AM To: dcarl...@tamu.edu; dcarl...@tamu.edu Cc: r-h...@stat.math.ethz.ch Subject: RE: [R] data.frame with NA Yes, colClasses is the solution. Thank you ver

Re: [R] data.frame with NA

2013-03-20 Thread Pietro
0 AM > To: dcarl...@tamu.edu; dcarl...@tamu.edu > Cc: r-h...@stat.math.ethz.ch > Subject: RE: [R] data.frame with NA > > Yes, colClasses is the solution. Thank you very much. > However i found a very strange thing. > > If i use: > Foglio1 <- read.xlsx2("mydb.xlsx", 1

Re: [R] data.frame with NA

2013-03-19 Thread PIKAL Petr
Hi > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > project.org] On Behalf Of Pietro > Sent: Tuesday, March 19, 2013 12:10 PM > To: dcarl...@tamu.edu; dcarl...@tamu.edu > Cc: r-h...@stat.math.ethz.ch > Subject: Re: [R] data.f

Re: [R] data.frame with NA

2013-03-19 Thread David L Carlson
ssociate Professor of Anthropology Texas A&M University College Station, TX 77843-4352 > -Original Message- > From: Pietro [mailto:freeri...@gmail.com] > Sent: Tuesday, March 19, 2013 6:10 AM > To: dcarl...@tamu.edu; dcarl...@tamu.edu > Cc: r-h...@stat.math.ethz.ch &g

Re: [R] data.frame with NA

2013-03-19 Thread Pietro
rg] On Behalf Of David L Carlson > Sent: Monday, March 18, 2013 3:22 PM > To: 'Pietro'; 'Berend Hasselman' > Cc: r-h...@stat.math.ethz.ch > Subject: Re: [R] data.frame with NA > > Try this > > Open the spreadsheet in Excel. Select all of the data click Cop

Re: [R] data.frame with NA

2013-03-18 Thread David L Carlson
David > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > project.org] On Behalf Of David L Carlson > Sent: Monday, March 18, 2013 3:22 PM > To: 'Pietro'; 'Berend Hasselman' > Cc: r-h...@stat.math.ethz.ch > Subject: R

Re: [R] data.frame with NA

2013-03-18 Thread David L Carlson
ion, TX 77843-4352 > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > project.org] On Behalf Of Pietro > Sent: Monday, March 18, 2013 1:57 PM > To: Berend Hasselman > Cc: r-h...@stat.math.ethz.ch > Subject: Re: [R] data.frame wit

Re: [R] data.frame with NA

2013-03-18 Thread Pietro
Yes, it's true Berend! What i do is simply use read.xlsx function db <- read.xlsx2("c:/mydb.xlsx",1,as.data.frame=T) This is excel file i use: http://dl.dropbox.com/u/102669/mydb.xlsx I can't find a way to import as numeric. My objective is to be able to work (in R) with my NA's At 18.46 1

Re: [R] data.frame with NA

2013-03-18 Thread Berend Hasselman
On 18-03-2013, at 19:57, Pietro wrote: > Yes, it's true Berend! > > What i do is simply use read.xlsx function > > db <- read.xlsx2("c:/mydb.xlsx",1,as.data.frame=T) > > This is excel file i use: > http://dl.dropbox.com/u/102669/mydb.xlsx > I don't have the required packages installed to r

Re: [R] data.frame with NA

2013-03-18 Thread Berend Hasselman
On 18-03-2013, at 16:49, Pete wrote: > > I have this little data.frame > > http://dl.dropbox.com/u/102669/nanotna.rdata > > Two column contains NA, so the best thing to do is use na.locf function (with > fromLast = T) > > But locf function doesn't work because NA in my data.frame are not rec