10X單細胞 && 10X空間轉(zhuǎn)錄組數(shù)據(jù)分析之量化樣本間異質(zhì)性

作者雪标,追風(fēng)少年i

國慶前的最后一周了,大家好好努力劳吠,有句臺詞說得好,Yesterday is history巩趁, Tomorrow is a mystery痒玩, But today is a gift That is why it’s called the present (the gift) 。

這一篇來回答一些項目中遇到的問題议慰,以及簡單分享一下如何衡量樣本間的異質(zhì)性蠢古。

最近很多老師來做分析,其中大多數(shù)拿著疾病的樣本别凹,然后告訴我做什么分析草讶,要分析什么老師也不知道,只是說做分析炉菲,搞得我難以下手堕战,簡單的課題設(shè)計還是要準(zhǔn)備好的坤溃。
  • 疾病樣本:其實單細胞樣本的分析本質(zhì)還是分組找差異,只是這個差異從更高的維度來分析嘱丢,無論是通訊的差異還是轉(zhuǎn)錄狀態(tài)的差異薪介,前提是有組可分,最理想的狀態(tài)就是normal和disease越驻,當(dāng)然很多老師無法取到normal的樣本汁政,那么臨床信息就顯得尤為重要,預(yù)后好和預(yù)后差之間的差異伐谈,才具有臨床指導(dǎo)的價值烂完。

  • 如果說僅僅有疾病樣本,臨床信息也沒有的前提下诵棵,是很難分析出有效的信息抠蚣,這個時候很多老師就開始探索單細胞數(shù)據(jù)庫,從數(shù)據(jù)庫的隊列中尋找normal的數(shù)據(jù)來進行分析履澳,方法是可取的嘶窄,但是要注意數(shù)據(jù)的匹配程度,平臺差異等等距贷。

  • 樣本的注釋問題柄冲,流程化的注釋是不可取的,多次強調(diào)過忠蝗,市面上都說新格元注釋做的好现横,也是浪費了很大的人工,并不是流程化帶來的阁最,資料和經(jīng)驗戒祠,也是科研工作者必備的素質(zhì)。

  • 樣本量的問題速种,單細胞發(fā)展到現(xiàn)在姜盈,僅靠一兩個樣本發(fā)文章是不現(xiàn)實的(二區(qū)及以上),無論從哪個角度分析配阵,都需要在多個樣本中驗證研究的價值馏颂,所以大家如果決定做單細胞分析,就要想好這一點棋傍。

好了救拉,關(guān)于課題設(shè)計,其實也是一個很大的學(xué)問瘫拣,這樣的工作通常是技術(shù)支持來做的亿絮,接下來分享一個簡單的內(nèi)容,衡量樣本間的異質(zhì)性。
  • 指標(biāo)1:Cluster entropy壹无,為了測量來自不同樣本的細胞在細胞類型cluster中的混合程度如何葱绒,量化了數(shù)據(jù)集的歸一化相對cluster entropy,按cluster大小加權(quán)斗锭。 cluster entropy為 1 表示樣本在cluster 之間完全混合地淀。
圖片.png

參考文章,10X單細胞(10X空間轉(zhuǎn)錄組)基因表達的熵值分析

圖片.png
  • 指標(biāo)2 :Similarity scores/alignment岖是,為了測量來自相同與不同批次和/或樣品的細胞之間細胞類型內(nèi)細胞狀態(tài)的轉(zhuǎn)錄變異帮毁,測量了每個樣品/批次之間的成對對齊(就是整合),其中批次由同一天處理的樣品組組成豺撑。 這個“相似度分?jǐn)?shù)”檢查特定樣本/批次中每個細胞的局部鄰域烈疚,詢問其 k 個最近鄰居中有多少個(在 PC 或 iNMF(這個大家應(yīng)該都知道) 空間中)屬于第二個樣本/批次,然后在所有細胞上取平均值 . 這里選擇 k 為cluster內(nèi)細胞總數(shù)的 1%聪轿。 結(jié)果通過每個樣品/批次的預(yù)期細胞數(shù)進行標(biāo)準(zhǔn)化爷肝。

最后匯總一下Seurat包的所有函數(shù)

函數(shù) 作用
AddModuleScore Calculate module scores for feature expression programs in single cells
AggregateExpression Aggregated feature expression by identity class
AnchorSet-class The AnchorSet Class
AnnotateAnchors Add info to anchor matrix
Assay-class The Assay Class
AugmentPlot Augments ggplot2-based plot with a PNG image.
AverageExpression Averaged feature expression by identity class
BGTextColor Determine text color based on background color
BarcodeInflectionsPlot Plot the Barcode Distribution and Calculated Inflection Points
BlackAndWhite Create a custom color palette
BuildClusterTree Phylogenetic Analysis of Identity Classes
CalcPerturbSig Calculate a perturbation Signature
CalculateBarcodeInflections Calculate the Barcode Distribution Inflection
CaseMatch Match the case of character vectors
CellCycleScoring Score cell cycle phases
CellScatter Cell-cell scatter plot
CellSelector Cell Selector
Cells.SCTModel Get Cell Names
CellsByImage Get a vector of cell names associated with an image (or set of images)
CollapseEmbeddingOutliers Move outliers towards center on dimension reduction plot
CollapseSpeciesExpressionMatrix Slim down a multi-species expression matrix,when only one species is primarily of interenst.
ColorDimSplit Color dimensional reduction plot by tree split
CombinePlots Combine ggplot2-based plots into a single plot
CreateSCTAssayObject Create a SCT Assay object
CustomDistance Run a custom distance function on an input data matrix
DEenrichRPlot DE and EnrichR pathway visualization barplot
DietSeurat Slim down a Seurat object
DimHeatmap Dimensional reduction heatmap
DimPlot Dimensional reduction plot
DimReduc-class The DimReduc Class
DiscretePalette Discrete colour palettes from the pals package
DoHeatmap Feature expression heatmap
DotPlot Dot plot visualization
ElbowPlot Quickly Pick Relevant Dimensions
ExpMean Calculate the mean of logged values
ExpSD Calculate the standard deviation of logged values
ExpVar Calculate the variance of logged values
FastRowScale Scale and/or center matrix rowwise
FeaturePlot Visualize 'features' on a dimensional reduction plot
FeatureScatter Scatter plot of single cell data
FilterSlideSeq Filter stray beads from Slide-seq puck
FindAllMarkers Gene expression markers for all identity classes
FindClusters Cluster Determination
FindConservedMarkers Finds markers that are conserved between the groups
FindIntegrationAnchors Find integration anchors
FindMarkers Gene expression markers of identity classes
FindMultiModalNeighbors Construct weighted nearest neighbor graph
FindNeighbors (Shared) Nearest-neighbor graph construction
FindSpatiallyVariableFeatures Find spatially variable features
FindSubCluster Find subclusters under one cluster
FindTransferAnchors Find transfer anchors
FindVariableFeatures Find variable features
FoldChange Fold Change
GetAssay Get an Assay object from a given Seurat object.
GetImage.SlideSeq Get Image Data
GetIntegrationData Get integration data
GetResidual Calculate pearson residuals of features not in the scale.data
GetTissueCoordinates.SlideSeq Get Tissue Coordinates
GetTransferPredictions Get the predicted identity
Graph-class The Graph Class
GroupCorrelation Compute the correlation of features broken down by groups with another covariate
GroupCorrelationPlot Boxplot of correlation of a variable (e.g.number of UMIs) with expression data
HTODemux Demultiplex samples based on data from cell 'hashing'
HTOHeatmap Hashtag oligo heatmap
HVFInfo.SCTAssay Get Variable Feature Information
HoverLocator Hover Locator
IFeaturePlot Visualize features in dimensional reduction space interactively
ISpatialDimPlot Visualize clusters spatially and interactively
ISpatialFeaturePlot Visualize features spatially and interactively
IntegrateData Integrate data
IntegrateEmbeddings Integrate low dimensional embeddings
IntegrationAnchorSet-class The IntegrationAnchorSet Class
IntegrationData-class The IntegrationData Class
JackStraw Determine statistical significance of PCA scores.
JackStrawData-class The JackStrawData Class
JackStrawPlot JackStraw Plot
L2CCA L2-Normalize CCA
L2Dim L2-normalization
LabelClusters Label clusters on a ggplot2-based scatter plot
LabelPoints Add text labels to a ggplot2 plot
LinkedPlots Visualize spatial and clustering (dimensional reduction) data in a linked, interactive framework
Load10X_Spatial Load a 10x Genomics Visium Spatial Experiment into a 'Seurat' object
LoadAnnoyIndex Load the Annoy index file
LoadSTARmap Load STARmap data
LocalStruct Calculate the local structure preservation metric
LogNormalize Normalize raw data
LogVMR Calculate the variance to mean ratio of logged values
MULTIseqDemux Demultiplex samples based on classification method from MULTI-seq
MapQuery Map query cells to a reference
MappingScore Metric for evaluating mapping success
MetaFeature Aggregate expression of multiple features into a single feature
MinMax Apply a ceiling and floor to all values in a matrix
MixingMetric Calculates a mixing metric
MixscapeHeatmap Differential expression heatmap for mixscape
MixscapeLDA Linear discriminant analysis on pooled CRISPR screen data.
ModalityWeights-class The ModalityWeights Class
NNPlot Highlight Neighbors in DimPlot
Neighbor-class The Neighbor Class
NormalizeData Normalize Data
PCASigGenes Significant genes from a PCA
PercentageFeatureSet Calculate the percentage of all counts that belong to a given set of features
PlotClusterTree Plot clusters as a tree
PlotPerturbScore Function to plot perturbation score distributions.
PolyDimPlot Polygon DimPlot
PolyFeaturePlot Polygon FeaturePlot
PredictAssay Predict value from nearest neighbors
PrepLDA Function to prepare data for Linear Discriminant Analysis.
PrepSCTIntegration Prepare an object list normalized with sctransform for integration.
ProjectDim Project Dimensional reduction onto full dataset
ProjectUMAP Project query into UMAP coordinates of reference
Radius.SlideSeq Get Spot Radius
Read10X Load in data from 10X
Read10X_Image Load a 10X Genomics Visium Image
Read10X_h5 Read 10X hdf5 file
ReadMtx Load in data from remote or local mtx files
ReadSlideSeq Load Slide-seq spatial data
RegroupIdents Regroup idents based on meta.data info
RelativeCounts Normalize raw data to fractions
RenameCells.SCTAssay Rename Cells in an Object
RidgePlot Single cell ridge plot
RunCCA Perform Canonical Correlation Analysis
RunICA Run Independent Component Analysis on gene expression
RunLDA Run Linear Discriminant Analysis
RunMarkVario Run the mark variogram computation on a given position matrix and expression matrix.
RunMixscape Run Mixscape
RunMoransI Compute Moran's I value.
RunPCA Run Principal Component Analysis
RunSPCA Run Supervised Principal Component Analysis
RunTSNE Run t-distributed Stochastic Neighbor Embedding
RunUMAP Run UMAP
SCTAssay-class The SCTModel Class
SCTResults Get SCT results from an Assay
SCTransform Use regularized negative binomial regression to normalize UMI count data
STARmap-class The STARmap class
SampleUMI Sample UMI
SaveAnnoyIndex Save the Annoy index
ScaleData Scale and center the data.
ScaleFactors Get image scale factors
ScoreJackStraw Compute Jackstraw scores significance.
SelectIntegrationFeatures Select integration features
SetIntegrationData Set integration data
Seurat-class The Seurat Class
Seurat-package Seurat: Tools for Single Cell Genomics
SeuratCommand-class The SeuratCommand Class
SeuratTheme Seurat Themes
SlideSeq-class The SlideSeq class
SpatialImage-class The SpatialImage Class
SpatialPlot Visualize spatial clustering and expression data.
SplitObject Splits object into a list of subsetted objects.
SubsetByBarcodeInflections Subset a Seurat Object based on the Barcode Distribution Inflection Points
TopCells Find cells with highest scores for a given dimensional reduction technique
TopFeatures Find features with highest scores for a given dimensional reduction technique
TopNeighbors Get nearest neighbors for given cell
TransferAnchorSet-class The TransferAnchorSet Class
TransferData Transfer data
UpdateSCTAssays Update pre-V4 Assays generated with SCTransform in the Seurat to the new SCTAssay class
UpdateSymbolList Get updated synonyms for gene symbols
VariableFeaturePlot View variable features
VisiumV1-class The VisiumV1 class
VizDimLoadings Visualize Dimensional Reduction genes
VlnPlot Single cell violin plot
as.CellDataSet Convert objects to CellDataSet objects
as.Seurat.CellDataSet Convert objects to 'Seurat' objects
as.SingleCellExperiment Convert objects to SingleCellExperiment objects
as.sparse.H5Group Cast to Sparse
cc.genes Cell cycle genes
cc.genes.updated.2019 Cell cycle genes: 2019 update
contrast-theory Get the intensity and/or luminance of a color
merge.SCTAssay Merge SCTAssay objects
subset.AnchorSet Subset an AnchorSet object

周一了,偷個懶陆错,生活很好灯抛,有你更好

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
禁止轉(zhuǎn)載,如需轉(zhuǎn)載請通過簡信或評論聯(lián)系作者音瓷。
  • 序言:七十年代末对嚼,一起剝皮案震驚了整個濱河市,隨后出現(xiàn)的幾起案子绳慎,更是在濱河造成了極大的恐慌纵竖,老刑警劉巖,帶你破解...
    沈念sama閱讀 206,126評論 6 481
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件杏愤,死亡現(xiàn)場離奇詭異靡砌,居然都是意外死亡,警方通過查閱死者的電腦和手機声邦,發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 88,254評論 2 382
  • 文/潘曉璐 我一進店門乏奥,熙熙樓的掌柜王于貴愁眉苦臉地迎上來摆舟,“玉大人亥曹,你說我怎么就攤上這事『抻眨” “怎么了媳瞪?”我有些...
    開封第一講書人閱讀 152,445評論 0 341
  • 文/不壞的土叔 我叫張陵,是天一觀的道長照宝。 經(jīng)常有香客問我蛇受,道長,這世上最難降的妖魔是什么厕鹃? 我笑而不...
    開封第一講書人閱讀 55,185評論 1 278
  • 正文 為了忘掉前任兢仰,我火速辦了婚禮乍丈,結(jié)果婚禮上,老公的妹妹穿的比我還像新娘把将。我一直安慰自己轻专,他們只是感情好,可當(dāng)我...
    茶點故事閱讀 64,178評論 5 371
  • 文/花漫 我一把揭開白布察蹲。 她就那樣靜靜地躺著请垛,像睡著了一般。 火紅的嫁衣襯著肌膚如雪洽议。 梳的紋絲不亂的頭發(fā)上宗收,一...
    開封第一講書人閱讀 48,970評論 1 284
  • 那天,我揣著相機與錄音亚兄,去河邊找鬼混稽。 笑死,一個胖子當(dāng)著我的面吹牛审胚,可吹牛的內(nèi)容都是我干的荚坞。 我是一名探鬼主播,決...
    沈念sama閱讀 38,276評論 3 399
  • 文/蒼蘭香墨 我猛地睜開眼菲盾,長吁一口氣:“原來是場噩夢啊……” “哼颓影!你這毒婦竟也來了?” 一聲冷哼從身側(cè)響起懒鉴,我...
    開封第一講書人閱讀 36,927評論 0 259
  • 序言:老撾萬榮一對情侶失蹤诡挂,失蹤者是張志新(化名)和其女友劉穎,沒想到半個月后临谱,有當(dāng)?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體璃俗,經(jīng)...
    沈念sama閱讀 43,400評論 1 300
  • 正文 獨居荒郊野嶺守林人離奇死亡,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點故事閱讀 35,883評論 2 323
  • 正文 我和宋清朗相戀三年悉默,在試婚紗的時候發(fā)現(xiàn)自己被綠了城豁。 大學(xué)時的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片。...
    茶點故事閱讀 37,997評論 1 333
  • 序言:一個原本活蹦亂跳的男人離奇死亡抄课,死狀恐怖唱星,靈堂內(nèi)的尸體忽然破棺而出,到底是詐尸還是另有隱情跟磨,我是刑警寧澤间聊,帶...
    沈念sama閱讀 33,646評論 4 322
  • 正文 年R本政府宣布,位于F島的核電站抵拘,受9級特大地震影響哎榴,放射性物質(zhì)發(fā)生泄漏。R本人自食惡果不足惜,卻給世界環(huán)境...
    茶點故事閱讀 39,213評論 3 307
  • 文/蒙蒙 一尚蝌、第九天 我趴在偏房一處隱蔽的房頂上張望迎变。 院中可真熱鬧,春花似錦飘言、人聲如沸氏豌。這莊子的主人今日做“春日...
    開封第一講書人閱讀 30,204評論 0 19
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽泵喘。三九已至,卻和暖如春般妙,著一層夾襖步出監(jiān)牢的瞬間纪铺,已是汗流浹背。 一陣腳步聲響...
    開封第一講書人閱讀 31,423評論 1 260
  • 我被黑心中介騙來泰國打工碟渺, 沒想到剛下飛機就差點兒被人妖公主榨干…… 1. 我叫王不留鲜锚,地道東北人。 一個月前我還...
    沈念sama閱讀 45,423評論 2 352
  • 正文 我出身青樓苫拍,卻偏偏與公主長得像芜繁,于是被迫代替她去往敵國和親。 傳聞我的和親對象是個殘疾皇子绒极,可洞房花燭夜當(dāng)晚...
    茶點故事閱讀 42,722評論 2 345

推薦閱讀更多精彩內(nèi)容