-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.qmd
68 lines (43 loc) · 1.25 KB
/
index.qmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
---
title: "mPFC-web"
author: ZhengHu
date: 2023.07.12
---
```{r}
#| echo: false
#| message: false
#| warning: false
library(vitessceR)
library(tidyverse)
library(SeuratDisk)
#Adult.Ex <- readRDS('data/Adult.Ex.rds')
```
## scRNAseq
```{r}
#| echo: false
#| message: false
#| warning: false
adata_url <- "https://huggingface.co/datasets/TigerZheng/PFCdata/resolve/main/Adult_Ex.zarr"
#adata_url <- "https://pfcweb.oss-rg-china-mainland.aliyuncs.com/Adult_Ex.zarr"
#adata_path <- "data/Adult_Ex.zarr"
vc <- VitessceConfig$new(schema_version = "1.0.0", name = "Adult_Ex config")
dataset <- vc$add_dataset(name = "Adult_Ex", uid = "Adult_Ex")
dataset <- dataset$add_object(AnnDataWrapper$new(
#adata_path = adata_path,
adata_url = adata_url,
obs_feature_matrix_path = "X",
obs_embedding_paths = c("obsm/X_umap"),
obs_embedding_names = c("UMAP"),
obs_set_paths = c("obs/SubType_Layer", "obs/SubType"),
obs_set_names = c("SubType_Layer", "SubType")
))
scatterplot_umap <- vc$add_view(dataset, Component$SCATTERPLOT, mapping = "UMAP")
cell_sets <- vc$add_view(dataset, Component$CELL_SETS)
genes <- vc$add_view(dataset, Component$GENES)
vc$layout(
hconcat(
scatterplot_umap,
vconcat(cell_sets, genes)
))
vc$widget(theme = "light")
```