test_that("test_export_seurat4", {
rhdf5::h5closeAll()
bcs.file <- file.path(tempdir(), "test.bcs")
if (file.exists(bcs.file)) file.remove(bcs.file)
mat <- CreateRandomSparseMatrix(200, 60)
obj <- Seurat::CreateSeuratObject(mat)
obj <- Seurat::NormalizeData(obj)
obj <- Seurat::FindVariableFeatures(obj)
obj <- Seurat::ScaleData(obj)
obj <- Seurat::RunPCA(obj)
obj <- Seurat::RunTSNE(obj, dims=1:30, perplexity=5)
expect_true(ExportSeurat(obj, bcs.file))
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.