Skip to content

data.frame does not support matrix types #324

@chrisconlon

Description

@chrisconlon

Consider the following example:

load(hflights)
hflights$taxi <- as.matrix(cbind(hflights$TaxiIn,hflights$TaxiOut))
grouped <- group_by(hflights,Year,Month)

Produces the error message:

Error: column 'taxi' has unsupported type

Is this the intended behavior? (To disallow matrix types in the group_by operation within a data.frame). This was working in 0.1.1 but not in 0.1.2

If so, what is the recommended workaround? My use case is similar to "Run a regression on each group" where the user specifies the regressors. It is much more efficient to split the design matrix than it is to create a new one for each group.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions