Skip to content

setDT could be much simpler #4476

@jangorecki

Description

@jangorecki

setDT function already grown pretty fat. AFAIK it was meant to be a low overhead function. Making it low overhead now would be challanging, or even impossible, without removing some of its features. Therefore it seems reasonable to introduce new argument, lets call it asis, that will make as few as possible, which is to set:

  • class
  • rownames
  • overalloc

Such a change would be helpful in case if someone wants to benchmark DT operations but for some reason would like to include time of as.data.table / as.data.frame (time of an extra deep copy). setDT already removes extra deep copy, but they have other stuff, that is unnecessary in a case of just changing class.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions