Skip to content

keep stored na in matrix products - #4

Open
buyan-kh wants to merge 1 commit into
Genentech:mainfrom
buyan-kh:fix/matrix-product-na
Open

buyan-kh wants to merge 1 commit into
Genentech:mainfrom
buyan-kh:fix/matrix-product-na

Conversation

@buyan-kh

@buyan-kh buyan-kh commented Dec 3, 2026 •

Copy link
Copy Markdown

fixes #3

sql sum skips nulls, so %*%, crossprod and tcrossprod turned a stored na into a number. the product sums now come back as na when any term is na, like base r and dgCMatrix. finite sums are unchanged.

added a test in tests/testthat/test-DuckDBMatrix.R that checks %*%, crossprod and tcrossprod against base r with a stored na.

@aboyounp-gne would you mind taking a look?

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.

%*%, crossprod and tcrossprod drop stored na values

1 participant