From ce176e7f89d80c0e34839a1a3d8a5200d7961e0b Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 21 Sep 2026 16:31:31 +0000 Subject: [PATCH 1/2] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/astral-sh/ruff-pre-commit: v0.16.2 → v0.16.8](https://github.com/astral-sh/ruff-pre-commit/compare/v0.16.2...v0.16.8) - [github.com/PyCQA/bandit: 1.7.9 → 1.9.4](https://github.com/PyCQA/bandit/compare/1.7.9...1.9.4) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index af3eb03..8874b0a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.16.2 + rev: v0.16.8 hooks: # Run the linter. - id: ruff-check @@ -55,7 +55,7 @@ repos: # - id: codespell - repo: https://github.com/PyCQA/bandit - rev: 1.7.9 + rev: 1.9.4 hooks: - id: bandit args: ["-c", "pyproject.toml"] From b8635c8208ce717c30bcf512cb649eae0e1deeba Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 21 Sep 2026 16:32:49 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- README.md | 72 ++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 45 insertions(+), 27 deletions(-) diff --git a/README.md b/README.md index 1831343..c5a6bb8 100644 --- a/README.md +++ b/README.md @@ -44,40 +44,60 @@ ncols = 6 counts = np.random.rand(nrows, ncols) gr = GenomicRanges( seqnames=[ - "chr1", - "chr2", - "chr2", - "chr2", - "chr1", - "chr1", - "chr3", - "chr3", - "chr3", - "chr3", - ] * 20, + "chr1", + "chr2", + "chr2", + "chr2", + "chr1", + "chr1", + "chr3", + "chr3", + "chr3", + "chr3", + ] + * 20, ranges=IRanges(range(100, 300), range(110, 310)), - strand = ["-", "+", "+", "*", "*", "+", "+", "+", "-", "-"] * 20, - mcols=BiocFrame({ - "score": range(0, 200), - "GC": [random() for _ in range(10)] * 20, - }) + strand=["-", "+", "+", "*", "*", "+", "+", "+", "-", "-"] * 20, + mcols=BiocFrame( + { + "score": range(0, 200), + "GC": [random() for _ in range(10)] * 20, + } + ), ) -col_data_sce = BiocFrame({"treatment": ["ChIP", "Input"] * 3}, +col_data_sce = BiocFrame( + {"treatment": ["ChIP", "Input"] * 3}, row_names=[f"sce_{i}" for i in range(6)], ) -col_data_se = BiocFrame({"treatment": ["ChIP", "Input"] * 3}, +col_data_se = BiocFrame( + {"treatment": ["ChIP", "Input"] * 3}, row_names=[f"se_{i}" for i in range(6)], ) -sample_map = BiocFrame({ - "assay": ["sce", "se"] * 6, - "primary": ["sample1", "sample2"] * 6, - "colname": ["sce_0", "se_0", "sce_1", "se_1", "sce_2", "se_2", "sce_3", "se_3", "sce_4", "se_4", "sce_5", "se_5"] -}) +sample_map = BiocFrame( + { + "assay": ["sce", "se"] * 6, + "primary": ["sample1", "sample2"] * 6, + "colname": [ + "sce_0", + "se_0", + "sce_1", + "se_1", + "sce_2", + "se_2", + "sce_3", + "se_3", + "sce_4", + "se_4", + "sce_5", + "se_5", + ], + } +) -sample_data = BiocFrame({"samples": ["sample1", "sample2"]}, row_names= ["sample1", "sample2"]) +sample_data = BiocFrame({"samples": ["sample1", "sample2"]}, row_names=["sample1", "sample2"]) ``` Finally, we can create an `MultiAssayExperiment` object: @@ -87,9 +107,7 @@ from multiassayexperiment import MultiAssayExperiment from singlecellexperiment import SingleCellExperiment from summarizedexperiment import SummarizedExperiment -tsce = SingleCellExperiment( - assays={"counts": counts}, row_data=gr.to_pandas(), column_data=col_data_sce -) +tsce = SingleCellExperiment(assays={"counts": counts}, row_data=gr.to_pandas(), column_data=col_data_sce) tse2 = SummarizedExperiment( assays={"counts": counts.copy()},