[Rd] readRDS and saveRDS

Joshua Wiley jwiley.psych at gmail.com
Tue Oct 18 21:16:46 CEST 2011


On Tue, Oct 18, 2011 at 9:34 AM, Duncan Murdoch
<murdoch.duncan at gmail.com> wrote:
> On 18/10/2011 9:37 AM, Hadley Wickham wrote:
>>
>> Hi all,
>>
>> Is there any chance that readRDS and saveRDS might one day become
>> read.rds and write.rds?  That would make them more consistent with the
>> other reading and writing functions.
>
> Ending names in .foo is a bad idea because of the S3 naming conventions, so
> I think this is unlikely.  But you can always create an alias yourself...

I always thought that S3 was part of the reason for read.ext write.ext. In:

"/path/file.ext"

the "class" of the file is "ext".  I kind of like the idea of taking
this farther, generic functions read/write dispatch to the appropriate
method depending on the class of the file.  Generally, only read/write
would be used, specifying the specific method as needed.  read.rda and
write.rda could replace load/save where: dat <- read.rda() would
create an environment, dat rather than simply loading them into the
global environment.

Though this is more of a hypothetical situation than a suggestion for change.


>
> Duncan Murdoch
>
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>



-- 
Joshua Wiley
Ph.D. Student, Health Psychology
Programmer Analyst II, ATS Statistical Consulting Group
University of California, Los Angeles
https://joshuawiley.com/



More information about the R-devel mailing list