Skip to content

Remove as.zoo.data.frame() #414

@joshuaulrich

Description

@joshuaulrich

quantmod::as.zoo.data.frame() overwrites zoo's S3 registry entry when quantmod is loaded. The quantmod method was added in 2007, and the zoo method was not added until 2010. The package that owns the class should define the conversion method, so the as.zoo.*() methods should be in zoo.

Removing quantmod::as.zoo.data.frame() may break user code, because it converts rownames to Date before using them as the index for the zoo object, and the zoo method only uses an integer index by default.

The migration was started in 9343d9a by by printing a message the first time the quantmod method is called. Throw a warning so the method can be removed in the next major release.

Related to #315.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions