From d414eb15e5ed586cceecceea445445311165e524 Mon Sep 17 00:00:00 2001 From: parashardhapola Date: Fri, 30 Jul 2021 13:37:09 +0200 Subject: [PATCH] updated docs for run_umap API change --- docs/source/vignettes/basic_tutorial_scATACseq.mdnb | 2 +- docs/source/vignettes/basic_tutorial_scRNAseq.mdnb | 2 +- docs/source/vignettes/data_projection.mdnb | 2 +- docs/source/vignettes/merging_datasets.mdnb | 4 ++-- docs/source/vignettes/multiple_modalities.mdnb | 4 ++-- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/docs/source/vignettes/basic_tutorial_scATACseq.mdnb b/docs/source/vignettes/basic_tutorial_scATACseq.mdnb index 8e19464..8a83340 100644 --- a/docs/source/vignettes/basic_tutorial_scATACseq.mdnb +++ b/docs/source/vignettes/basic_tutorial_scATACseq.mdnb @@ -75,7 +75,7 @@ Non-linear dimension reduction using UMAP and tSNE are performed in the same way ```python -ds.run_umap(fit_n_epochs=250, min_dist=0.5, parallel=True) +ds.run_umap(n_epochs=250, min_dist=0.5, parallel=True) ``` ```python diff --git a/docs/source/vignettes/basic_tutorial_scRNAseq.mdnb b/docs/source/vignettes/basic_tutorial_scRNAseq.mdnb index 7a31df1..2d048f3 100644 --- a/docs/source/vignettes/basic_tutorial_scRNAseq.mdnb +++ b/docs/source/vignettes/basic_tutorial_scRNAseq.mdnb @@ -159,7 +159,7 @@ ds.make_graph(feat_key='hvgs', k=11, dims=15, n_centroids=100) Next we run UMAP on the graph calculated above. Here we will not provide which cell key or feature key to be used, because we want the UMAP to run on all the cells that were not filtered out and with the feature key used to calculate the latest graph. We can provide the parameter values for the UMAP algorithm here. ```python -ds.run_umap(fit_n_epochs=250, spread=5, min_dist=1, parallel=True) +ds.run_umap(n_epochs=250, spread=5, min_dist=1, parallel=True) ``` The UMAP results are saved in the cell metadata table as seen below in columns: **RNA_UMAP1** and **RNA_UMAP2** diff --git a/docs/source/vignettes/data_projection.mdnb b/docs/source/vignettes/data_projection.mdnb index 1a09f49..4a42ff0 100644 --- a/docs/source/vignettes/data_projection.mdnb +++ b/docs/source/vignettes/data_projection.mdnb @@ -135,7 +135,7 @@ Scarf introduces Unified UMAPs, a strategy to embed target cells onto the refere ```python ds_ctrl.run_unified_umap(target_names=['stim'], ini_embed_with='RNA_UMAP', target_weight=1, - use_k=5, fit_n_epochs=100, tx_n_epochs=10) + use_k=5, n_epochs=100) ``` Since the results of unified embedding contain 'foreign' cells, `plot_layout` function cannot be used to visualize all the cells. A specialized method, `plot_unified_layout` takes care of this issue. The following example shows co-embedded control (reference) and stimulated (target) PBMCs. diff --git a/docs/source/vignettes/merging_datasets.mdnb b/docs/source/vignettes/merging_datasets.mdnb index bca1a25..903a480 100644 --- a/docs/source/vignettes/merging_datasets.mdnb +++ b/docs/source/vignettes/merging_datasets.mdnb @@ -141,7 +141,7 @@ ds.make_graph(feat_key='hvgs', k=21, dims=25, n_centroids=100) Calculating UMAP embedding of cells: ```python -ds.run_umap(fit_n_epochs=250, spread=5, min_dist=1, parallel=True) +ds.run_umap(n_epochs=250, spread=5, min_dist=1, parallel=True) ``` ```python @@ -185,7 +185,7 @@ ds.make_graph(feat_key='hvgs', k=21, dims=25, n_centroids=100, pca_cell_key='is_ We run UMAP as usual, but the UMAP embeddings are saved in a new cell attribute column so as to not overwrite the previous UMAP values. The new column will be called `RNA_pUMAP`; 'RNA' is automatically prepend because the assay name is `RNA` ```python -ds.run_umap(fit_n_epochs=250, spread=5, min_dist=1, parallel=True, label='pUMAP') +ds.run_umap(n_epochs=250, spread=5, min_dist=1, parallel=True, label='pUMAP') ``` Visualize the new UMAP diff --git a/docs/source/vignettes/multiple_modalities.mdnb b/docs/source/vignettes/multiple_modalities.mdnb index 28ee51c..a991518 100644 --- a/docs/source/vignettes/multiple_modalities.mdnb +++ b/docs/source/vignettes/multiple_modalities.mdnb @@ -98,7 +98,7 @@ Now we process the RNA assay to perform feature selection, create KNN graph, run ```python ds.mark_hvgs(min_cells=20, top_n=500, min_mean=-3, max_mean=2, max_var=6) ds.make_graph(feat_key='hvgs', k=11, dims=15, n_centroids=100) -ds.run_umap(fit_n_epochs=250, spread=5, min_dist=1, parallel=True) +ds.run_umap(n_epochs=250, spread=5, min_dist=1, parallel=True) ds.run_leiden_clustering(resolution=1) ``` @@ -153,7 +153,7 @@ ds.make_graph(from_assay='ADT', feat_key='I', k=11, dims=11, n_centroids=100) UMAP and clustering can be run on ADT assay by simply setting `from_assay` parameter value to 'ADT': ```python -ds.run_umap(from_assay='ADT', fit_n_epochs=250, spread=5, min_dist=1, parallel=True) +ds.run_umap(from_assay='ADT', n_epochs=250, spread=5, min_dist=1, parallel=True) ds.run_leiden_clustering(from_assay='ADT', resolution=1) ```