diff --git a/README.md b/README.md index 9fda9a55..d4cb5ef5 100644 --- a/README.md +++ b/README.md @@ -76,7 +76,7 @@ let qc_thresholds = scran.suggestRnaQcFilters(qc_metrics); let filtered = scran.filterCells(mat, qc_thresholds.filter(qc_metrics)); // Log-normalizing. -let normalized = scran.logNormCounts(filtered); +let normalized = scran.normalizeCounts(filtered); // Modelling per-gene variance and selecting top HVGs. let varmodel = scran.modelGeneVariances(normalized); @@ -90,7 +90,7 @@ let index = scran.buildNeighborSearchIndex(pcs); // Performing the clustering. let cluster_graph = scran.buildSnnGraph(index, { neighbors: 10 }); -let clustering = scran.clusterSnnGraph(cluster_graph); +let clustering = scran.clusterGraph(cluster_graph); // Performing the t-SNE and UMAP. let tsne_res = scran.runTsne(index); @@ -114,7 +114,7 @@ Developer notes are also available [here](docs/related/developer_notes.md). ## Links -Check out [kana](https://github.com/jkanche/kana) to see how **scran.js** is used in an interactive scRNA-seq analysis application. +Check out [kana](https://github.com/kanaverse/kana) to see how **scran.js** is used in an interactive scRNA-seq analysis application. -The [**scran.chan**](https://github.com/LTLA/scran.chan) R package and [**scran**](https://github.com/LTLA/scran-cli) executable +The [**scrapper**](https://github.com/libscran/scrapper) R package and [**scran**](https://github.com/LTLA/scran-cli) executable are based on the same C++ libraries and allow the same analysis to be performed in different environments. diff --git a/docs/related/cell_type_annotation.md b/docs/related/cell_type_annotation.md index 5ca00129..41cb6c7f 100644 --- a/docs/related/cell_type_annotation.md +++ b/docs/related/cell_type_annotation.md @@ -18,14 +18,14 @@ Several datasets have been processed and made available [here](https://github.co Assuming the files have been downloaded and are available as `ArrayBuffer`s, we load the reference: ```js -let loaded = scran.loadLabelledReferenceFromBuffers(rankbuf, markbuf, labbuf); // files 1, 2 and 3, respectively. +let loaded = scran.loadLabelCellsReferenceFromBuffers(rankbuf, markbuf, labbuf); // files 1, 2 and 3, respectively. ``` We then build the reference given `testfeatures`, an array with the names of the features in our test dataset; and `reffeatures`, an array with the names of the features in our reference (extracted from file **4**). ```js -let built = scran.buildLabelledReference(testfeatures, loaded, reffeatures); +let built = scran.trainLabelCellsReference(testfeatures, loaded, reffeatures); ``` Finally, we can generate labels from our input matrix. @@ -44,12 +44,12 @@ Advanced users can integrate cell labels from multiple references with the `inte Firstly, we classify our test dataset against each of the references individually: ```js -let loaded_A = scran.loadLabelledReferenceFromBuffers(rankbuf_A, markbuf_A, labbuf_A); -let built_A = scran.buildLabelledReference(testfeatures, loaded_A, reffeatures_A); +let loaded_A = scran.loadLabelCellsReferenceFromBuffers(rankbuf_A, markbuf_A, labbuf_A); +let built_A = scran.trainLabelCellsReference(testfeatures, loaded_A, reffeatures_A); let labels_A = scran.labelCells(mat, built_A); -let loaded_B = scran.loadLabelledReferenceFromBuffers(rankbuf_B, markbuf_B, labbuf_B); -let built_B = scran.buildLabelledReference(testfeatures, loaded_B, reffeatures_B); +let loaded_B = scran.loadLabelCellsReferenceFromBuffers(rankbuf_B, markbuf_B, labbuf_B); +let built_B = scran.trainLabelCellsReference(testfeatures, loaded_B, reffeatures_B); let labels_B = scran.labelCells(mat, built_B); ``` @@ -57,11 +57,12 @@ We then integrate the references and the associated labels to obtain a single se More specifically, this chooses the best reference for each cell, based on each reference's best cell type call for that cell. ```js -let interbuilt = scran.integrateLabelledReferences(testfeatures, +let interbuilt = scran.integrateLabelCellsReferences( + testfeatures, [loaded_A, loaded_B], [reffeatures_A, reffeatures_B], [built_A, built_B] ); -let interlabels = scran.integrateCellLabels(mat, [labels_A, labels_B], inter); +let interlabels = scran.integrateLabelCells(mat, [labels_A, labels_B], inter); ``` diff --git a/js/modelGeneVariances.js b/js/modelGeneVariances.js index 0522f6a0..9cc8caa6 100644 --- a/js/modelGeneVariances.js +++ b/js/modelGeneVariances.js @@ -61,7 +61,6 @@ export class ModelGeneVariancesResults { * @return {Float64Array|Float64WasmArray} Array of length equal to the number of genes, * containing the fitted value of the mean-variance trend for the specified `block` * (or the average across all blocks, if `block = null`). - * Alternatively `null`, if `fillable = false` and the array was not already filled. */ fitted(options = {}) { const { block = null, copy = true, ...others } = options; diff --git a/js/suggestRnaQcFilters.js b/js/suggestRnaQcFilters.js index 2d73e29f..afb49343 100644 --- a/js/suggestRnaQcFilters.js +++ b/js/suggestRnaQcFilters.js @@ -146,7 +146,6 @@ export function suggestRnaQcFilters(metrics, options = {}) { /** * Create an empty {@linkplain SuggestRnaQcFiltersResults} object, to be filled with custom results. - * Note that filling requires use of `fillable: true` in the various getters to obtain a writeable memory view. * * @param {number} numberOfSubsets Number of feature subsets. * @param {number} numberOfBlocks Number of blocks in the dataset.