Skip to content

Support Matrix return types#225

Merged
eddelbuettel merged 6 commits intomasterfrom
de/as_matrix
Apr 2, 2021
Merged

Support Matrix return types#225
eddelbuettel merged 6 commits intomasterfrom
de/as_matrix

Conversation

@eddelbuettel
Copy link
Copy Markdown
Contributor

This PR implements something discussed following #222: for (dense) arrays with row and colum indices, we can optionally return a Matrix object (in addition to the existing default of a list of vectors, and the existing data.frame option.

To illustrate, consider the quickstart_dense example:

> library(tiledb)
> arr <- tiledb_array("quickstart_dense", as.matrix=TRUE)
> arr[]
     [,1] [,2] [,3] [,4]
[1,]    1    2    3    4
[2,]    5    6    7    8
[3,]    9   10   11   12
[4,]   13   14   15   16
> 

In case more than one attribute is returned from a query, a list of matrices is returned.

@eddelbuettel eddelbuettel merged commit 7dfe331 into master Apr 2, 2021
@eddelbuettel eddelbuettel deleted the de/as_matrix branch April 2, 2021 22:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants