Package: pagoda2 1.0.12

Evan Biederstedt

pagoda2: Single Cell Analysis and Differential Expression

Analyzing and interactively exploring large-scale single-cell RNA-seq datasets. 'pagoda2' primarily performs normalization and differential gene expression analysis, with an interactive application for exploring single-cell RNA-seq datasets. It performs basic tasks such as cell size normalization, gene variance normalization, and can be used to identify subpopulations and run differential expression within individual samples. 'pagoda2' was written to rapidly process modern large-scale scRNAseq datasets of approximately 1e6 cells. The companion web application allows users to explore which gene expression patterns form the different subpopulations within your data. The package also serves as the primary method for preprocessing data for conos, <https://github.com/kharchenkolab/conos>. This package interacts with data available through the 'p2data' package, which is available in a 'drat' repository. To access this data package, see the instructions at <https://github.com/kharchenkolab/pagoda2>. The size of the 'p2data' package is approximately 6 MB.

Authors:Nikolas Barkas [aut], Viktor Petukhov [aut], Peter Kharchenko [aut], Simon Steiger [ctb], Rasmus Rydbirk [ctb], Evan Biederstedt [cre, aut]

pagoda2_1.0.12.tar.gz
pagoda2_1.0.12.zip(r-4.5)pagoda2_1.0.12.zip(r-4.4)pagoda2_1.0.12.zip(r-4.3)
pagoda2_1.0.12.tgz(r-4.4-x86_64)pagoda2_1.0.12.tgz(r-4.4-arm64)pagoda2_1.0.12.tgz(r-4.3-arm64)pagoda2_1.0.12.tgz(r-4.3-x86_64)
pagoda2_1.0.12.tar.gz(r-4.5-noble)pagoda2_1.0.12.tar.gz(r-4.4-noble)
pagoda2_1.0.12.tgz(r-4.4-emscripten)pagoda2_1.0.12.tgz(r-4.3-emscripten)
pagoda2.pdf |pagoda2.html
pagoda2/json (API)

# Install 'pagoda2' in R:
install.packages('pagoda2', repos = c('https://kharchenkolab.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/kharchenkolab/pagoda2/issues

Uses libs:
  • openblas– Optimized BLAS
  • c++– GNU Standard C++ Library v3
  • openmp– GCC OpenMP (GOMP) support library

On CRAN:

scrna-seqsingle-cellsingle-cell-rna-seqtranscriptomics

56 exports 203 stars 5.60 score 65 dependencies 4 mentions 260 scripts 778 downloads

Last updated 7 months agofrom:92befcdc35. Checks:OK: 9. Indexed: yes.

TargetResultDate
Doc / VignettesOKAug 25 2024
R-4.5-win-x86_64OKAug 25 2024
R-4.5-linux-x86_64OKAug 25 2024
R-4.4-win-x86_64OKAug 25 2024
R-4.4-mac-x86_64OKAug 25 2024
R-4.4-mac-aarch64OKAug 25 2024
R-4.3-win-x86_64OKJul 26 2024
R-4.3-mac-aarch64OKJul 26 2024
R-4.3-mac-x86_64OKJul 26 2024

Exports:armaCorbasicP2procbasicP2webbuildWijMatrixcalcMulticlassifiedcellsPerSelectionGroupcollapse.aspect.clusterscompareClusteringsextendedP2procfactorFromP2SelectionfactorListToMetadatafactorToP2selectiongene.vs.molecule.cell.filtergenerateClassificationAnnotationget.control.genesetget.de.genesetgetCellsInSelectionsgetClusterLabelsFromSelectiongetColorsFromP2SelectiongetIntExtNamesP2SelectionhierDiffToGenesetsmake.p2.appminMaxScalenamedNamesp2.generate.dr.gop2.generate.gop2.generate.human.gop2.generate.mouse.gop2.make.pagoda1.appp2.metadata.from.factorp2.toweb.hdeap2ViewPagodaApppagoda.reduce.loading.redundancypagoda.reduce.redundancyPagoda2pathway.pc.correlation.distanceplotMulticlassifiedplotOneWithValuesplotSelectionOverlapsprojectKNNsread.10x.matricesread10xMatrixreadPagoda2SelectionAsFactorreadPagoda2SelectionFileremoveSelectionOverlapsscore.cells.nb0score.cells.puramsgdBatchesshow.appsubsetSignatureToDatatp2c.view.pathwaysvalidateSelectionsObjectwebP2procwinsorize.matrixwriteGenesAsPagoda2SelectionwritePagoda2SelectionFile

Dependencies:BHbrewclicolorspacecpp11dendsortdplyrdqrngdratfansifarverfastclusterFNNgenericsggplot2ggrepelgluegtableigraphirlbaisobandlabelinglatticelifecyclemagrittrMASSMatrixmgcvmunsellN2RnlmepbmcapplypillarpkgconfigplyrpROCR.methodsS3R.ooR.utilsR6RColorBrewerRcppRcppAnnoyRcppArmadilloRcppEigenRcppProgressRcppSpdlogrjsonrlangRMTstatRookRSpectraRtsnescalessccoresitmotibbletidyselecttriebeardurltoolsutf8uwotvctrsviridisLitewithr

Readme and manuals

Help Manual

Help pageTopics
armaCor - matrix column correlations. Allows faster matrix correlations with armadillo. Similar to cor() call, will calculate correlation between matrix columnsarmaCor
Perform basic 'pagoda2' processing, i.e. adjust variance, calculate pca reduction, make knn graph, identify clusters with multilevel, and generate largeVis and tSNE embeddings.basicP2proc
Generate a 'pagoda2' web application from a 'Pagoda2' objectbasicP2web
Rescale the weights in an edge matrix to match a given perplexity. From 'largeVis', <https://github.com/elbamos/largeVis>buildWijMatrix
Returns a list vector with the number of cells that are present in more than one selections in the provided p2 selection objectcalcMulticlassified
Get the number of cells in each selection groupcellsPerSelectionGroup
Collapse aspect patterns into clusterscollapse.aspect.clusters
Compare two different clusterings provided as factors by plotting a normalised heatmapcompareClusterings
Perform extended 'Pagoda2' processing. Generate organism specific GO environment and calculate pathway overdispersion.extendedP2proc
Returns a factor of cell membership from a p2 selection object the factor only includes cells present in the selection. If the selection contains multiclassified cells an error is raisedfactorFromP2Selection
Converts a list of factors into 'pagoda2' metadata optionally filtering down to the cells present in the provided 'pagoda2' app.factorListToMetadata
Converts a names factor to a p2 selection object if colors are provided it assigns those, otherwise uses a rainbow palettefactorToP2selection
Filter cells based on gene/molecule dependencygene.vs.molecule.cell.filter
Given a cell clustering (partitioning) and a set of user provided selections generate a cleaned up annotation of cluster groups that can be used for classificationgenerateClassificationAnnotation
Get a control geneset for cell scoring using the method described in Puram, Bernstein (Cell, 2018)get.control.geneset
Generate differential expression genesets for the web app given a cell grouping by calculating DE sets between each cell set and everything elseget.de.geneset
Returns all the cells that are in the designated selections. Given a pagoda2 selections object and the names of some selections in it returns the names of the cells that are in these selections removed any duplicatesgetCellsInSelections
Assign names to the clusters, given a clustering vector and a set of selections. This function will use a set of pagoda2 cell seletcion to identify the clusters in a a named factor. It is meant to be used to import user defined annotations that are defined as selections into a more formal categorization of cells that are defined by cluster. To help with this the function allows a percent of cells to have been classified in the selections into multiple groups, something which may be the result of the users making wrong selections. The percent of cells allows to be multiselected in any given group is defined by multiClassCutoff. Furthermore the method will assign each cluster to a selection only if the most popular cluster to the next most popular exceed the ambiguous.ratio in terms of cell numbers. If a cluster does not satisfy this condtiion it is not assigned.getClusterLabelsFromSelection
Retrieves the colors of each selection from a p2 selection object as a names vector of stringsgetColorsFromP2Selection
Get a mapping form internal to external names for the specified selection objectgetIntExtNamesP2Selection
Converts the output of hierarchical differential expression aspects into genesets that can be loaded into a 'pagoda2' web app to retrive the genes that make the geneset interactivelyhierDiffToGenesets
Generate a Rook Server app from a 'Pagoda2' object. This generates a 'pagoda2' web object from a 'Pagoda2' object by automating steps that most users will want to run. This function is a wrapper about the 'pagoda2' web constructor. (Advanced users may wish to use that constructor directly.)make.p2.app
Scale the designated values between the range of 0 and 1minMaxScale
Get a vector of the names of an object named by the names themselves. This is useful with lapply when passing names of objects as it ensures that the output list is also named.namedNames
Generate a GO environment for human for overdispersion analysis for the the back endp2.generate.dr.go
Generate a GO environment for the organism specifiedp2.generate.go
Generate a GO environment for human for overdispersion analysis for the the back endp2.generate.human.go
Generate a GO environment for mouse for overdispersion analysis for the the back endp2.generate.mouse.go
Create 'PAGODA1' web application from a 'Pagoda2' object 'PAGODA1' found here, with 'SCDE': <https://www.bioconductor.org/packages/release/bioc/html/scde.html>p2.make.pagoda1.app
Generate a list metadata structure that can be passed to a 'pagoda2' web object constructor as additional metadata given a named factorp2.metadata.from.factor
Generate a 'pagoda2' web object from a 'Pagoda2' object using hierarchical differential expressionp2.toweb.hdea
p2ViewPagodaApp R6 classp2ViewPagodaApp
Collapse aspects driven by the same combinations of genes. (Aspects are some pattern across cells e.g. sequencing depth, or PC corresponding to an undesired process such as ribosomal pathway variation.) Examines PC loading vectors underlying the identified aspects and clusters of aspects based on a product of loading and score correlation (raised to corr.power). Clusters of aspects driven by the same genes are determined based on the parameter "distance.threshold".pagoda.reduce.loading.redundancy
Collapse aspects driven by similar patterns (i.e. separate the same sets of cells) Examines PC loading vectors underlying the identified aspects and clusters aspects based on score correlation. Clusters of aspects driven by the same patterns are determined based on the distance.threshold.pagoda.reduce.redundancy
pagoda2WebApp_arrayToJSONpagoda2WebApp_arrayToJSON
pagoda2WebApp_availableAspectsJSONpagoda2WebApp_availableAspectsJSON
pagoda2WebApp_callpagoda2WebApp_call
pagoda2WebApp_cellmetadataJSONpagoda2WebApp_cellmetadataJSON
pagoda2WebApp_cellOrderJSONpagoda2WebApp_cellOrderJSON
pagoda2WebApp_geneInformationJSONpagoda2WebApp_geneInformationJSON
Generate a dendrogram of groupspagoda2WebApp_generateDendrogramOfGroups
pagoda2WebApp_generateEmbeddingStructurepagoda2WebApp_generateEmbeddingStructure
pagoda2WebApp_generateGeneKnnJSONpagoda2WebApp_generateGeneKnnJSON
pagoda2WebApp_getCompressedEmbeddingpagoda2WebApp_getCompressedEmbedding
pagoda2WebApp_packCompressFloat64Arraypagoda2WebApp_packCompressFloat64Array
pagoda2WebApp_packCompressInt32Arraypagoda2WebApp_packCompressInt32Array
pagoda2WebApp_readStaticFilepagoda2WebApp_readStaticFile
pagoda2WebApp_reducedDendrogramJSONpagoda2WebApp_reducedDendrogramJSON
pagoda2WebApp_serializeToStaticFastpagoda2WebApp_serializeToStaticFast
pagoda2WebApp_serverLogpagoda2WebApp_serverLog
pagoda2WebApp_sparseMatListpagoda2WebApp_sparseMatList
pagoda2WebApp class to create 'pagoda2' web applications via a Rook serverpagoda2WebApp pagoda2WebApp-class
Calculate correlation distance between PC magnitudes given a number of target dimensionspathway.pc.correlation.distance
Plot multiclassified cells per selection as a percent barplotplotMulticlassified
Plot the embedding of a 'Pagoda2' object with the given valuesplotOneWithValues
Get a dataframe and plot summarising overlaps between selection of a pagoda2 selection object ignore self overlapsplotSelectionOverlaps
Project a distance matrix into a lower-dimensional space. (from elbamos/largeVis)projectKNNs
Quick loading of 10X CellRanger count matricesread.10x.matrices
This function reads a matrix generated by the 10x processing pipeline from the specified directory and returns it. It aborts if one of the required files in the specified directory do not exist.read10xMatrix
Read a pagoda2 cell selection file and return it as a factor while removing any mutliclassified cellsreadPagoda2SelectionAsFactor
Reads a 'pagoda2' web app exported cell selection file exported as a list of list objects that contain the name of the selection, the color (as a hex string) and the identifiers of the individual cellsreadPagoda2SelectionFile
Remove cells that are present in more than one selection from all the selections they are inremoveSelectionOverlaps
Score cells by getting mean expression of genes in signaturesscore.cells.nb0
Puram, Bernstein (Cell, 2018) Score cells as described in Puram, Bernstein (Cell, 2018)score.cells.puram
Calculate the default number of batches for a given number of vertices and edges. The formula used is the one used by the 'largeVis' reference implementation. This is substantially less than the recommendation E * 10000 in the original paper.sgdBatches
Directly open the 'pagoda2' web application and view the 'p2web' application object from our R sessionshow.app
Subset a gene signature to the genes in the given matrix with optional warning if genes are missingsubsetSignatureToData
View pathway or gene-weighted PCA 'Pagoda2' version of the function pagoda.show.pathways() Takes in a list of pathways (or a list of genes), runs weighted PCA, optionally showing the result.tp2c.view.pathways
Validates a pagoda2 selection objectvalidateSelectionsObject
Generate a 'pagoda2' web objectwebP2proc
Sets the ncol(mat)*trim top outliers in each row to the next lowest value same for the lowest outlierswinsorize.matrix
Writes a list of genes as a gene selection that can be loaded in the web interfacewriteGenesAsPagoda2Selection
Writes a pagoda2 selection object as a p2 selection file that be be loaded to the web interfacewritePagoda2SelectionFile