[datatable-help] fread will not respect stringsAsFactors

Arunkumar Srinivasan aragorn168b at gmail.com
Wed Apr 30 15:04:48 CEST 2014


Hi Frank,

IIRC it's not implemented yet (irrespective of R or data.table version). I think there's a bug/FR somewhere. Matt hasn't gotten to it yet.

Arun

From: Frank Harrell f.harrell at vanderbilt.edu
Reply: Frank Harrell f.harrell at vanderbilt.edu
Date: April 30, 2014 at 2:28:46 PM
To: datatable-help at lists.r-forge.r-project.org datatable-help at lists.r-forge.r-project.org
Subject:  [datatable-help] fread will not respect stringsAsFactors  

In R 3.1.0 and data.table 1.9.2, I can't get stringsAsFactors to work:  

require(data.table)  
s=fread('http://biostat.mc.vanderbilt.edu/tmp/support2.csv',  
stringsAsFactors=TRUE)  
attributes(s$sex) # NULL; is character  

Frank  

_______________________________________________  
datatable-help mailing list  
datatable-help at lists.r-forge.r-project.org  
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/datatable-help  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/datatable-help/attachments/20140430/3fdaae82/attachment.html>


More information about the datatable-help mailing list