Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
87 commits
Select commit Hold shift + click to select a range
1dfd61f
[cpp] add version detection for highway
immanuelazn Jul 16, 2025
ae2e4a9
[cpp] cleanup highway detection in configure
immanuelazn Jul 16, 2025
fc3f935
[cpp] fix syntax error in `configure.win`
immanuelazn Jul 16, 2025
c1e6586
[cpp] fix configure styling and gitignore
immanuelazn Jul 16, 2025
e6e1286
update NEWS.md
immanuelazn Jul 16, 2025
3af9e75
[r][cpp] wip
immanuelazn Jul 21, 2025
8ab1098
Merge remote-tracking branch 'origin/main' into ia/cran-release-prep
immanuelazn Oct 1, 2025
e87a3f4
[r] various changes + licensing for CRAN
immanuelazn Oct 16, 2025
090f660
[r] fix majority of issues with notes and warnings (except roxygen is…
immanuelazn Oct 17, 2025
33d8b8c
[r] add in all styling fixes for CRAN
immanuelazn Oct 21, 2025
7681e32
[r] add some small ci cleanup, version bump
immanuelazn Oct 21, 2025
9a8dd09
[ci] move around r dependency flags for drat
immanuelazn Oct 21, 2025
1a57cad
[ci] move around r dependency flags for drat
immanuelazn Oct 21, 2025
60d8f27
[cpp] remove linker optimizations not allowed with cran
immanuelazn Oct 22, 2025
b6088a2
[ci] check removing highway compilation from rbuildignore
immanuelazn Oct 22, 2025
29c078c
[ci] check removing highway compilation from configure
immanuelazn Oct 22, 2025
cdca012
[cpp] test highway
immanuelazn Oct 22, 2025
a229baf
[cpp] check with adding tools/highway back into .Rbuildignore
immanuelazn Oct 22, 2025
faf6c65
[ci] add cran check
immanuelazn Oct 22, 2025
10d409d
[ci] cleanup cran check
immanuelazn Oct 22, 2025
8b53a66
[ci] cleanup cran check
immanuelazn Oct 22, 2025
846ace2
[r] wrap macs example in case ci doesn't have macs
immanuelazn Oct 22, 2025
bc971fd
[r] wrap macs examples p2
immanuelazn Oct 22, 2025
4fa4517
[ci] error on r cmd check only on error
immanuelazn Oct 22, 2025
cfbda00
[ci] fix ci errors
immanuelazn Oct 22, 2025
f07c6d5
[ci] fix ci errors
immanuelazn Oct 22, 2025
b6998eb
[ci] try vendoring highway for cran
immanuelazn Oct 22, 2025
5eba2b8
[ci] add in more comprehensive systemrequirements
immanuelazn Oct 22, 2025
620f075
[r] update data locations for human_gene_mapping
immanuelazn Oct 23, 2025
99d68f5
[r] reorganize docs for iterablematrix-methods
immanuelazn Oct 29, 2025
58ca719
[r] remove unnecessary params in IterableMatrix-methods-misc
immanuelazn Oct 29, 2025
385015d
[r] misc documentation changes
immanuelazn Nov 10, 2025
3d63e81
remove event.json
immanuelazn Nov 20, 2025
4ca1b4e
add hexbin back into imports
immanuelazn Nov 20, 2025
44f70e5
change windows check for cran ci
immanuelazn Nov 24, 2025
a13091a
Merge branch 'main' into ia/cran-release-prep
immanuelazn Nov 24, 2025
4a1c686
update configure.win to also use sh instead of bash
immanuelazn Nov 24, 2025
278d25c
disable timestamp check for windows
immanuelazn Nov 24, 2025
1841d70
check removing future file timestamps entirely in ci
immanuelazn Nov 24, 2025
b3da9a3
set the correct env variable to remove time check in ci
immanuelazn Nov 24, 2025
ca3f870
see if this turns off the timestamp issue in windows
immanuelazn Nov 24, 2025
d4e1212
change trackplot rendering to use ragg::wrap
immanuelazn Nov 24, 2025
2a2a575
update Makevars.in
immanuelazn Nov 24, 2025
39a730e
add env check on check-standard-test.yaml
immanuelazn Nov 24, 2025
09ba9a7
remove some importFrom calls in BPCells-package.R
immanuelazn Nov 24, 2025
fae9542
check timing change
immanuelazn Nov 24, 2025
793926b
undo importFrom changes
immanuelazn Nov 25, 2025
b81f8c9
test
immanuelazn Nov 25, 2025
89d0ade
remove syntax error in trackplots.R
immanuelazn Nov 26, 2025
5e9b8e1
add some code cleanup to removve some cmd check warnings
immanuelazn Nov 26, 2025
28b5bc1
add cleanup.win, misc leftovers from last commit
immanuelazn Nov 26, 2025
6861ced
add ragg changes, clean up coesion docs
immanuelazn Nov 26, 2025
a985756
add cleanup to iterablematrix-methods documentation
immanuelazn Dec 2, 2025
c453c40
remove removal of hitools/highway
immanuelazn Dec 2, 2025
f59e003
clean up various R docs pages
immanuelazn Dec 2, 2025
e2574be
continue cleaning up docs
immanuelazn Dec 2, 2025
32605ad
remove errant extra chars on plot_tss_scatter() leading to syntax error
immanuelazn Dec 2, 2025
08c928d
remove windows checks for timestamp in cran checks (seems broken still)
immanuelazn Dec 2, 2025
63f0d2f
clean up r documentation, break up r iterable matrix methods into sev…
immanuelazn Dec 2, 2025
a84ba0f
small cran fixes
immanuelazn Dec 5, 2025
31e616a
fix some plotting issues in docs
immanuelazn Dec 5, 2025
0a208dd
[r] add missing code snippets from trackplot_combine.Rd
immanuelazn Dec 15, 2025
3415788
[r] misc docs cleanups
immanuelazn Dec 16, 2025
28988b0
Merge branch 'main' into ia/cran-release-prep
immanuelazn Dec 16, 2025
0467ce5
update NEWS.md
immanuelazn Dec 16, 2025
4dbba4b
[r] fix chr levels bug in `footprint()`
immanuelazn Dec 16, 2025
c9f9c6c
[r] fix docs package for `trackplot_calculate_segment_height()`
immanuelazn Dec 16, 2025
c88b36a
[r] add cxx17_filesystem cleanup
immanuelazn Dec 16, 2025
8de3b88
[r][cpp][python] change all http to https
immanuelazn Dec 16, 2025
4ec69a0
[cpp] add highway changes to pass R CMD check
immanuelazn Jan 8, 2026
3f9bcdd
[r] add TFMPvalue forcibly to requirements
immanuelazn Jan 8, 2026
243d8d4
[r] delete artifacts
immanuelazn Jan 8, 2026
fd475e6
[r] reduce TFMPvalue required version
immanuelazn Jan 8, 2026
221e3c3
[r] set long examples to skip cran execution
immanuelazn Jan 8, 2026
9045ead
[ci] turn off NOT_CRAN for R CMD CHECK
immanuelazn Jan 8, 2026
f310745
[r][ci] set NOT_CRAN flag to use R_RUN_LONG_EXAMPLES instead
immanuelazn Jan 9, 2026
459928f
add email to immanuel
immanuelazn Jan 9, 2026
c8c63fc
[r] set to plain skipping examples
immanuelazn Jan 9, 2026
d0bb2a1
[r] add tiny internal data for examples (<100 kb)
immanuelazn Jan 9, 2026
44416e2
[r] make examples use precomputed data
immanuelazn Jan 9, 2026
72a8b1b
[r] cleanup examples
immanuelazn Jan 10, 2026
31dac0d
[r] add more examples
immanuelazn Jan 11, 2026
d8563cf
[r] add in colVars() specialization examples
immanuelazn Jan 11, 2026
c8bdbbd
[r] expand examples to all exported functions
immanuelazn Jan 11, 2026
1397c15
[r] update old gene scores example
immanuelazn Jan 11, 2026
f991ef9
[r] shorten write_insertion_bed() example runtime
immanuelazn Jan 13, 2026
daccc81
[r] remove demo frag retrieval in write_insertion_bedgraph() example
immanuelazn Jan 13, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
105 changes: 105 additions & 0 deletions .github/workflows/check-standard-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
name: R-CMD-check

on:
pull_request:
branches: [main]
workflow_dispatch:

jobs:
R-CMD-check:
runs-on: ${{ matrix.os }}
name: ${{ matrix.os }}
timeout-minutes: 120

strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]

env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes
ENABLE_INSTALL_COUNTING: no
_R_CHECK_BUILD_VIGNETTES_: false

steps:
- uses: actions/checkout@v4
- name: Install binary dependencies on ubuntu
if: matrix.os == 'ubuntu-latest'
shell: bash
run: |
sudo apt-get update
sudo apt-get install -y libhdf5-dev libhwy-dev
sudo apt-get isntall -y libhwy-dev || true

- name: Install binary dependencies on macOS
if: matrix.os == 'macos-latest' || matrix.os == 'macos-13'
shell: bash
run: |
brew update
brew install hdf5 pkg-config highway

- name: Configure compilation flags
shell: bash
run: |
cat <<'MAKEVARS' > "$GITHUB_WORKSPACE/Makevars.user"
MAKEFLAGS=--jobs=3
MAKEVARS
echo "R_MAKEVARS_USER=$GITHUB_WORKSPACE/Makevars.user" >> "$GITHUB_ENV"

- name: Install Highway on Windows (MSYS2 UCRT64)
if: matrix.os == 'windows-latest'
uses: msys2/setup-msys2@v2
with:
release: false
update: true
cache: true
install: >-
base-devel
git
mingw-w64-ucrt-x86_64-toolchain
mingw-w64-ucrt-x86_64-pkgconf
mingw-w64-ucrt-x86_64-highway
msystem: UCRT64
path-type: minimal

- name: Expose UCRT64 pkg-config to PATH (Windows)
if: matrix.os == 'windows-latest'
shell: bash
run: |
echo "C:/msys64/ucrt64/bin" >> $GITHUB_PATH
# Ensure pkg-config finds the .pc files for UCRT64
echo "PKG_CONFIG_PATH=C:/msys64/ucrt64/lib/pkgconfig" >> $GITHUB_ENV
echo "PKG_CONFIG=C:/msys64/ucrt64/bin/pkg-config.exe" >> $GITHUB_ENV

- name: Handle Windows big object files
if: matrix.os == 'windows-latest'
shell: bash
run: |
echo "CXXFLAGS += -Wa,-mbig-obj" >> "$GITHUB_WORKSPACE/Makevars.user"

- uses: r-lib/actions/setup-r@v2
with:
Ncpus: '3'
use-public-rspm: true
extra-repositories: |
https://bioconductor.org/packages/release/data/annotation
https://bpcells.github.io/drat

- uses: r-lib/actions/setup-r-dependencies@v2
with:
cache-version: 1
extra-packages: |
any::testthat
any::decor
working-directory: 'r'
needs: check
- name: Check package
uses: r-lib/actions/check-r-package@v2
with:
working-directory: r
build_args: c("--no-build-vignettes")
upload-snapshots: false
error-on: '"error"'


6 changes: 6 additions & 0 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ jobs:
run: bash -c 'echo -e "MAKEFLAGS=--jobs=3\nCXXFLAGS += -O1 -UNDEBUG" > "$GITHUB_WORKSPACE/Makevars.user" && echo "R_MAKEVARS_USER=$GITHUB_WORKSPACE/Makevars.user" >> "$GITHUB_ENV"'
- name: Setup R
uses: r-lib/actions/setup-r@v2
with:
Ncpus: '3'
use-public-rspm: true
extra-repositories: |
https://bioconductor.org/packages/release/data/annotation
https://bpcells.github.io/drat
- name: Install R dependencies
uses: r-lib/actions/setup-r-dependencies@v2
with:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/deploy-full-website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@ jobs:
run: bash -c 'echo -e "MAKEFLAGS=--jobs=3\nCXXFLAGS += -O1 -UNDEBUG" > "$GITHUB_WORKSPACE/Makevars.user" && echo "R_MAKEVARS_USER=$GITHUB_WORKSPACE/Makevars.user" >> "$GITHUB_ENV"'
- name: Setup R
uses: r-lib/actions/setup-r@v2
with:
Ncpus: '3'
use-public-rspm: true
extra-repositories: |
https://bioconductor.org/packages/release/data/annotation
https://bpcells.github.io/drat
- name: Install R dependencies
uses: r-lib/actions/setup-r-dependencies@v2
with:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/r-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ jobs:
with:
Ncpus: '3'
use-public-rspm: true
extra-repositories: |
https://bioconductor.org/packages/release/data/annotation
https://bpcells.github.io/drat
- uses: r-lib/actions/setup-r-dependencies@v2
with:
cache-version: 1
Expand Down
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ Package: BPCells.installation.moved
Title: Dummy package to provide new BPCells installation location
Version: 0.0.0.9000
Description: This package prints an error message upon attempted installation
License: Apache-2.0 or MIT
License: Apache License (== 2.0) | MIT + file LICENSE
Encoding: UTF-8
2 changes: 1 addition & 1 deletion python/docs/source/notebooks/fragment_basics.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ cluster_order = sorted(set(clusters))
cell_groups_array = bpcells.experimental.build_cell_groups(fragments_bpcells_path, barcodes, clusters, cluster_order)

# We could provide a dict or local file path, but URL is easier
chrom_sizes = "http://hgdownload.cse.ucsc.edu/goldenpath/hg38/bigZips/hg38.chrom.sizes"
chrom_sizes = "https://hgdownload.cse.ucsc.edu/goldenpath/hg38/bigZips/hg38.chrom.sizes"

insertions_matrix_path = os.path.join(tmpdir.name, "bpcells_insertions_matrix")

Expand Down
2 changes: 1 addition & 1 deletion python/tests/test_real_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def test_500_pbmc_matrix(tmp_path, fetch_cached_file):
peaks_path = fetch_cached_file("https://cf.10xgenomics.com/samples/cell-atac/2.0.0/atac_pbmc_500_nextgem/atac_pbmc_500_nextgem_peaks.bed")
peak_matrix_path = fetch_cached_file("https://cf.10xgenomics.com/samples/cell-atac/2.0.0/atac_pbmc_500_nextgem/atac_pbmc_500_nextgem_raw_peak_bc_matrix.h5")
barcode_metrics_path = fetch_cached_file("https://cf.10xgenomics.com/samples/cell-atac/2.0.0/atac_pbmc_500_nextgem/atac_pbmc_500_nextgem_singlecell.csv")
chrom_sizes_path = fetch_cached_file("http://hgdownload.cse.ucsc.edu/goldenpath/hg38/bigZips/hg38.chrom.sizes")
chrom_sizes_path = fetch_cached_file("https://hgdownload.cse.ucsc.edu/goldenpath/hg38/bigZips/hg38.chrom.sizes")


# Convert BPCells fragments
Expand Down
11 changes: 10 additions & 1 deletion r/.Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
^_pkgdown\.yml$
^compile_commands\.json$
^index\.md$
^docs$
^scripts$
^data-raw$
^pkgdown$
^.*\.Rproj$
^\.Rproj\.user$
^tools/highway$

^\.idea
^\.cache$
^bench$
^vignettes$

.*\.o$
.*\.so$
Expand All @@ -15,4 +22,6 @@
build/$
cmake-build-debug/
\.vscode/
\.snakemake/
\.snakemake/

^cran-comments\.md$
53 changes: 41 additions & 12 deletions r/DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,31 +1,34 @@
Package: BPCells
Title: Single Cell Counts Matrices to PCA
Version: 0.3.1
Version: 0.3.2
Authors@R: c(
person(given = "Benjamin",
family = "Parks",
role = c("aut", "cre", "cph"),
email = "bparks@alumni.stanford.edu",
comment = c(ORCID = "0000-0002-0261-7472")),
person("Immanuel", "Abdi", role = "aut"),
person("Immanuel", "Abdi", email = "immanuelazn@berkeley.edu", role = "aut"),
person("Stanford University", role=c("cph", "fnd")),
person("Genentech, Inc.", role=c("cph", "fnd")))
Description: > Efficient operations for single cell ATAC-seq fragments and
Description: Efficient operations for single cell ATAC-seq fragments and
RNA counts matrices. Interoperable with standard file formats, and introduces
efficient bit-packed formats that allow large storage savings and increased
read speeds.
License: Apache-2.0 or MIT
License: Apache License (>= 2) | MIT + file LICENSE
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.3.2
RoxygenNote: 7.3.3
Roxygen: list(markdown = TRUE)
URL: https://bnprks.github.io/BPCells, https://github.com/bnprks/BPCells
URL: https://bnprks.github.io/BPCells/, https://github.com/bnprks/BPCells
LinkingTo:
Rcpp,
RcppEigen
Imports:
Imports:
methods,
grDevices,
graphics,
stats,
utils,
magrittr,
Matrix,
Rcpp,
Expand All @@ -36,22 +39,48 @@ Imports:
stringr,
tibble,
dplyr (>= 1.0.0),
tidyr,
readr,
ggplot2 (>= 3.4.0),
scales,
patchwork,
ragg,
purrr,
scattermore,
ggrepel,
RColorBrewer,
hexbin
RColorBrewer
Suggests:
IRanges,
tidyr,
hexbin,
GenomicRanges,
GenomeInfoDb,
S4Vectors,
matrixStats,
MatrixGenerics,
RSpectra,
igraph,
RcppHNSW,
RcppAnnoy
RcppAnnoy,
Seurat,
pkgdown,
devtools,
uwot,
irlba,
BiocManager,
BSgenome.Hsapiens.UCSC.hg38,
TFMPvalue (>= 0.0.5),
motifmatchr,
chromVARmotifs,
png,
testthat (>= 3.0.0)
Additional_repositories:
https://bioconductor.org/packages/release/data/annotation,
https://bpcells.github.io/drat
Depends:
R (>= 4.0.0)
Config/Needs/website: pkgdown, devtools, uwot, irlba, RcppHNSW, igraph, BiocManager, bioc::BSgenome.Hsapiens.UCSC.hg38, github::GreenleafLab/motifmatchr, github::GreenleafLab/chromVARmotifs, png, magrittr
SystemRequirements: C++17,
HDF5 (>= 1.10) [optional; detected via pkg-config 'hdf5' or 'h5cc';
else set HDF5_CFLAGS/HDF5_LIBS],
Highway (>= 1.0.5) [optional; detected via pkg-config 'libhwy'/'hwy';
falls back to vendored build if not found]
Config/Needs/website: pkgdown, devtools, uwot, irlba, RcppHNSW, igraph, BiocManager, bioc::BSgenome.Hsapiens.UCSC.hg38, github::GreenleafLab/motifmatchr, github::GreenleafLab/chromVARmotifs, png
2 changes: 2 additions & 0 deletions r/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
YEAR: 2025
COPYRIGHT HOLDER: BPCells contributors
26 changes: 20 additions & 6 deletions r/NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,12 @@ export(cluster_graph_louvain)
export(cluster_graph_seurat)
export(colMaxs)
export(colMaxs.IterableMatrix)
export(colMaxs.default)
export(colMeans)
export(colQuantiles)
export(colQuantiles.IterableMatrix)
export(colQuantiles.default)
export(colSums)
export(colVars)
export(colVars.IterableMatrix)
export(colVars.default)
export(collect_features)
export(continuous_palette)
export(convert_matrix_type)
Expand Down Expand Up @@ -92,6 +89,7 @@ export(plot_tss_scatter)
export(prefix_cell_names)
export(pseudobulk_matrix)
export(qc_scATAC)
export(ragg_wrap)
export(range_distance_to_nearest)
export(read_bed)
export(read_encode_blacklist)
Expand All @@ -104,15 +102,13 @@ export(remove_demo_data)
export(rotate_x_labels)
export(rowMaxs)
export(rowMaxs.IterableMatrix)
export(rowMaxs.default)
export(rowMeans)
export(rowQuantiles)
export(rowQuantiles.IterableMatrix)
export(rowQuantiles.default)
export(rowSums)
export(rowVars)
export(rowVars.IterableMatrix)
export(rowVars.default)
export(scale_next_plot_height)
export(sctransform_pearson)
export(select_cells)
export(select_chromosomes)
Expand Down Expand Up @@ -144,6 +140,7 @@ export(write_matrix_anndata_hdf5_dense)
export(write_matrix_dir)
export(write_matrix_hdf5)
export(write_matrix_memory)
exportMethods("dimnames<-")
exportMethods(as.data.frame)
exportMethods(as.matrix)
exportMethods(t)
Expand All @@ -154,6 +151,9 @@ importFrom(Matrix,rowMeans)
importFrom(Matrix,rowSums)
importFrom(Matrix,t)
importFrom(Rcpp,sourceCpp)
importFrom(ggplot2,element_text)
importFrom(ggplot2,theme)
importFrom(graphics,text)
importFrom(magrittr,"%>%")
importFrom(methods,.hasSlot)
importFrom(methods,Arith)
Expand All @@ -162,6 +162,7 @@ importFrom(methods,Math)
importFrom(methods,Math2)
importFrom(methods,as)
importFrom(methods,callNextMethod)
importFrom(methods,canCoerce)
importFrom(methods,cbind2)
importFrom(methods,is)
importFrom(methods,new)
Expand All @@ -171,6 +172,19 @@ importFrom(methods,setClass)
importFrom(methods,setGeneric)
importFrom(methods,setMethod)
importFrom(methods,show)
importFrom(ragg,agg_png)
importFrom(stats,as.formula)
importFrom(stats,end)
importFrom(stats,model.matrix)
importFrom(stats,p.adjust)
importFrom(stats,ppois)
importFrom(stats,qpois)
importFrom(stats,quantile)
importFrom(stats,start)
importFrom(utils,download.file)
importFrom(utils,head)
importFrom(utils,tail)
importFrom(utils,untar)
importMethodsFrom(Matrix,colMeans)
importMethodsFrom(Matrix,colSums)
importMethodsFrom(Matrix,rowMeans)
Expand Down
Loading
Loading