MichaelChirico / r-bugs

A ⚠️read-only⚠️mirror of https://bugs.r-project.org/
20 stars 0 forks source link

[BUGZILLA #2764] bug in read.table #1692

Closed MichaelChirico closed 4 years ago

MichaelChirico commented 4 years ago

From: "Man, Michael" <Michael.Man@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::>> Hi, there might be a bug in read.delim (also read.table) in R.1.6.2. I included the correct input done in R1.6.1 first, then the wrong input in R1.6.2. The discrepancies are highlighted in red.

Michael Man

####### correct input in R1.6.1 ##########################

version
     _              

platform i386-pc-mingw32 arch i386
os mingw32
system i386, mingw32
status
major 1
minor 6.1
year 2002
month 11
day 01
language R

Browse[1]> jk2_read.delim(hd.file,sep="\t") Browse[1]> jk2[4:6,] Wells Drug Time Dose Animal.number Replicate 4 A4 Control 2 a 5 A5 Control 2 b 6 A6 Control 2 c

##### bug below ######################

version
     _              

platform i386-pc-mingw32 arch i386
os mingw32
system i386, mingw32
status
major 1
minor 6.2
year 2003
month 01
day 10
language R

Browse[1]> jk2_read.delim(hd.file,sep="\t") Browse[1]> jk2[4:6,1:6] AWells Drug Time Dose Animal.number Replicate 4 A4 Control 2 a
5 5 Control 2 b
6 A6 Control 2 c

LEGAL NOTICE\ Unless expressly stated otherwise, this message is... {{dropped}}


METADATA

MichaelChirico commented 4 years ago

From: Prof Brian Ripley <ripley@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::>> Without the file, how can we do anything about this? My guess is that this is a MacOS file, in which case the problem is PR#2469 which is long solved. Please try R-patched or a beta of R-1.7.0.

From the NEWS file in R-patched

BUG FIXES

o   The fix to PR#2396 broke read.table() on files with CR line
    endings. (PR#2469) Separate problem with this on Carbon Mac
    build fixed as well.

The other workaround is to use files in the native file format ....

BTW, `_' is deprecated, so please don't use it in postings, especially in the unreadable way shown here.

On Fri, 11 Apr 2003 Michael.Man@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> wrote:

Hi, there might be a bug in read.delim (also read.table) in R.1.6.2.  I
included the correct input done in R1.6.1 first, then the wrong input in
R1.6.2.  The discrepancies are highlighted in red.

Michael Man  

####### correct input in R1.6.1 ##########################
> version
_              
platform i386-pc-mingw32
arch     i386           
os       mingw32        
system   i386, mingw32  
status                  
major    1              
minor    6.1            
year     2002           
month    11             
day      01             
language R  

Browse[1]> jk2_read.delim(hd.file,sep="\t")
Browse[1]> jk2[4:6,]
Wells    Drug Time Dose Animal.number Replicate
4    A4 Control                       2         a
5    A5 Control                       2         b
6    A6 Control                       2         c

##### bug below ######################
> version
_              
platform i386-pc-mingw32
arch     i386           
os       mingw32        
system   i386, mingw32  
status                  
major    1              
minor    6.2            
year     2003           
month    01             
day      10             
language R             

Browse[1]> jk2_read.delim(hd.file,sep="\t")
Browse[1]> jk2[4:6,1:6]
AWells    Drug Time Dose Animal.number Replicate 
4      A4 Control                       2         a   
5       5 Control                       2         b   
6      A6 Control                       2         c 

LEGAL NOTICE\ Unless expressly stated otherwise, this message is...
{{dropped}}

______________________________________________
R-devel@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-devel

-- Brian D. Ripley, ripley@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ <CENSORING FROM DETECTED PHONE NUMBER ONWARDS; SEE BUGZILLA>


METADATA

MichaelChirico commented 4 years ago

Audit (from Jitterbug): Fri Apr 11 17:54:39 2003 thomas moved from incoming to not-reproducible


METADATA

MichaelChirico commented 4 years ago

From: "Man, Michael" <Michael.Man@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::>> Professor Ripley,

Thanks for your help. The file was indeed generated on MacOS, which was unknown to me till I checked with the sender.

Michael

-----Original Message----- From: Prof Brian Ripley [mailto:ripley@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::>] Sent: Friday, April 11, 2003 10:15 AM To: Michael.Man@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> Cc: r-devel@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::>; R-bugs@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> Subject: Re: [Rd] bug in read.table (PR#2764)

Without the file, how can we do anything about this? My guess is that this is a MacOS file, in which case the problem is PR#2469 which is long solved. Please try R-patched or a beta of R-1.7.0.

From the NEWS file in R-patched

BUG FIXES

o   The fix to PR#2396 broke read.table() on files with CR line
    endings. (PR#2469) Separate problem with this on Carbon Mac
    build fixed as well.

The other workaround is to use files in the native file format ....

BTW, `_' is deprecated, so please don't use it in postings, especially in the unreadable way shown here.

On Fri, 11 Apr 2003 Michael.Man@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> wrote:

Hi, there might be a bug in read.delim (also read.table) in R.1.6.2.  I
included the correct input done in R1.6.1 first, then the wrong input in
R1.6.2.  The discrepancies are highlighted in red.

Michael Man  

####### correct input in R1.6.1 ##########################
> version
_              
platform i386-pc-mingw32
arch     i386           
os       mingw32        
system   i386, mingw32  
status                  
major    1              
minor    6.1            
year     2002           
month    11             
day      01             
language R  

Browse[1]> jk2_read.delim(hd.file,sep="\t")
Browse[1]> jk2[4:6,]
Wells    Drug Time Dose Animal.number Replicate
4    A4 Control                       2         a
5    A5 Control                       2         b
6    A6 Control                       2         c

##### bug below ######################
> version
_              
platform i386-pc-mingw32
arch     i386           
os       mingw32        
system   i386, mingw32  
status                  
major    1              
minor    6.2            
year     2003           
month    01             
day      10             
language R             

Browse[1]> jk2_read.delim(hd.file,sep="\t")
Browse[1]> jk2[4:6,1:6]
AWells    Drug Time Dose Animal.number Replicate 
4      A4 Control                       2         a   
5       5 Control                       2         b   
6      A6 Control                       2         c 

LEGAL NOTICE\ Unless expressly stated otherwise, this message is...

{{dropped}}


______________________________________________
R-devel@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-devel

-- Brian D. Ripley, ripley@<::CENSORED -- SEE ORIGINAL ON BUGZILLA::> Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ <CENSORING FROM DETECTED PHONE NUMBER ONWARDS; SEE BUGZILLA>


METADATA