Last updated: 2021-12-13

Checks: 6 1

Knit directory: Embryoid_Body_Pilot_Workflowr/analysis/

This reproducible R Markdown analysis was created with workflowr (version 1.6.2). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.


Great! Since the R Markdown file has been committed to the Git repository, you know the exact version of the code that produced these results.

Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it's best to always run the code in an empty environment.

The command set.seed(20200804) was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.

Great job! Recording the operating system, R version, and package versions is critical for reproducibility.

Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.

Using absolute paths to the files within your workflowr project makes it difficult for you and others to run your code on a different machine. Change the absolute path(s) below to the suggested relative path(s) to make your code more reproducible.

absolute relative
/project2/gilad/katie/Pilot_HumanEBs/Embryoid_Body_Pilot_Workflowr/output/NEW_Pseudobulk_Limma_res0.5_OnevAllTopTables.csv ../output/NEW_Pseudobulk_Limma_res0.5_OnevAllTopTables.csv

Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.

The results in this page were generated with repository version 42fd51c. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.

Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish or wflow_git_commit). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:


Ignored files:
    Ignored:    .Rhistory
    Ignored:    .Rproj.user/
    Ignored:    analysis/.Rhistory
    Ignored:    analysis/figure/
    Ignored:    output/.Rhistory

Untracked files:
    Untracked:  GSE122380_raw_counts.txt.gz
    Untracked:  UTF1_plots.Rmd
    Untracked:  analysis/DoubletFinderTest.Rmd
    Untracked:  analysis/IntegrateReference_SCTregressCaoPlusScHCL_5newAndOriginal3.Rmd
    Untracked:  analysis/OLD/
    Untracked:  analysis/child/
    Untracked:  build_refint_5new.R
    Untracked:  build_refint_scale.R
    Untracked:  build_refint_sct.R
    Untracked:  build_stuff.R
    Untracked:  build_varpart_sc.R
    Untracked:  code/.ipynb_checkpoints/
    Untracked:  code/CellRangerPreprocess.Rmd
    Untracked:  code/GEO_processed_data.Rmd
    Untracked:  code/GEO_processed_data_additionalLines.Rmd
    Untracked:  code/PowerAnalysis_NoiseRatio.ipynb
    Untracked:  code/Rplots.pdf
    Untracked:  code/Untitled.ipynb
    Untracked:  code/Untitled1.ipynb
    Untracked:  data/HCL_Fig1_adata.h5ad
    Untracked:  data/HCL_Fig1_adata.h5seurat
    Untracked:  data/dge/
    Untracked:  data/dge_raw_data.tar.gz
    Untracked:  data/ref.expr.rda
    Untracked:  figure/
    Untracked:  output/5NEWLINES.BroadCellTypeCatAssignment.basedonclustersres0.15.csv
    Untracked:  output/5NEWLINES.Frequency.MostCommonAnnotation.FiveNearestRefCells.csv
    Untracked:  output/5NEWLINES.MostCommonAnnotation.FiveNearestRefCells.csv
    Untracked:  output/5NEWLINES.NearestReferenceCell.Cao.hESC.EuclideanDistanceinHarmonySpace.csv
    Untracked:  output/5NEWLINES.NearestReferenceCell.Cao.hESC.FrequencyofEachAnnotation.csv
    Untracked:  output/5newlines.merge.all.SCTwRegressOrigIdent.Harmony.rds
    Untracked:  output/CR_sampleQCrds/
    Untracked:  output/CaoEtAl.Obj.CellsOfAllClusters.ProteinCodingGenes.rds
    Untracked:  output/CaoEtAl.Obj.rds
    Untracked:  output/ClusterInfo_res0.1.csv
    Untracked:  output/DGELists/
    Untracked:  output/DoubletFinderTestSweepResults.RData
    Untracked:  output/DoubletFinderTestWITHknowndoublets.RData
    Untracked:  output/DownSampleVarPart.rds
    Untracked:  output/FiveNewLinesBarcodes.csv
    Untracked:  output/Frequency.MostCommonAnnotation.FiveNearestRefCells.csv
    Untracked:  output/GEOsubmissionProcessedFiles/
    Untracked:  output/GEOsubmission_additionalLines/
    Untracked:  output/GeneLists_by_minPCT/
    Untracked:  output/MostCommonAnnotation.FiveNearestRefCells.csv
    Untracked:  output/NEW_Pseudobulk_Limma_res0.1_OnevAllTopTables.csv
    Untracked:  output/NEW_Pseudobulk_Limma_res0.5_OnevAllTopTables.csv
    Untracked:  output/NEW_Pseudobulk_Limma_res0.8_OnevAllTopTables.csv
    Untracked:  output/NEW_Pseudobulk_Limma_res1_OnevAllTopTables.csv
    Untracked:  output/NearestReferenceCell.Cao.hESC.EuclideanDistanceinHarmonySpace.csv
    Untracked:  output/NearestReferenceCell.Cao.hESC.FrequencyofEachAnnotation.csv
    Untracked:  output/NearestReferenceCell.SCTregressRNAassay.Cao.hESC.EuclideanDistanceinHarmonySpace.csv
    Untracked:  output/NearestReferenceCell.SCTregressRNAassay.Cao.hESC.FrequencyofEachAnnotation.csv
    Untracked:  output/NewAndOriginal.merge.all.SCTwRegressOrigIdent.Harmony.rds
    Untracked:  output/Pseudobulk_Limma_res0.1_OnevAllTopTables.csv
    Untracked:  output/Pseudobulk_Limma_res0.1_OnevAll_top10Upregby_adjP.csv
    Untracked:  output/Pseudobulk_Limma_res0.1_OnevAll_top10Upregby_logFC.csv
    Untracked:  output/Pseudobulk_Limma_res0.5_OnevAllTopTables.csv
    Untracked:  output/Pseudobulk_Limma_res0.8_OnevAllTopTables.csv
    Untracked:  output/Pseudobulk_Limma_res1_OnevAllTopTables.csv
    Untracked:  output/Pseudobulk_VarPart.ByCluster.Res0.1.rds
    Untracked:  output/ResidualVariances_fromDownSampAnalysis.csv
    Untracked:  output/SingleCell_VariancePartition_RNA_Res0.1_minPCT0.2.rds
    Untracked:  output/SingleCell_VariancePartition_Res0.1_minPCT0.2.rds
    Untracked:  output/SingleCell_VariancePartition_SCT_Res0.1_minPCT0.2.rds
    Untracked:  output/TopicModelling_k10_top10drivergenes.byBeta.csv
    Untracked:  output/TopicModelling_k6_top10drivergenes.byBeta.csv
    Untracked:  output/TopicModelling_k6_top15drivergenes.byZ.csv
    Untracked:  output/TranferredAnnotations_ReferenceInt_JustEarlyEcto.csv
    Untracked:  output/TranferredAnnotations_ReferenceInt_JustEndoderm.csv
    Untracked:  output/TranferredAnnotations_ReferenceInt_JustMeso.csv
    Untracked:  output/TranferredAnnotations_ReferenceInt_JustNeuralCrest.csv
    Untracked:  output/TranferredAnnotations_ReferenceInt_JustNeuron.csv
    Untracked:  output/TranferredAnnotations_ReferenceInt_JustPluripotent.csv
    Untracked:  output/VarPart.ByCluster.Res0.1.rds
    Untracked:  output/azimuth/
    Untracked:  output/downsamp_10800cells_10subreps_medianexplainedbyresiduals_varpart_PsB.rds
    Untracked:  output/downsamp_16200cells_10subreps_medianexplainedbyresiduals_varpart_PsB.rds
    Untracked:  output/downsamp_21600cells_10subreps_medianexplainedbyresiduals_varpart_PsB.rds
    Untracked:  output/downsamp_2700cells_10subreps_medianexplainedbyresiduals_varpart_PsB.rds
    Untracked:  output/downsamp_2700cells_10subreps_medianexplainedbyresiduals_varpart_scres.rds
    Untracked:  output/downsamp_5400cells_10subreps_medianexplainedbyresiduals_varpart_PsB.rds
    Untracked:  output/downsamp_7200cells_10subreps_medianexplainedbyresiduals_varpart_PsB.rds
    Untracked:  output/fasttopics/
    Untracked:  output/figs/
    Untracked:  output/merge.Cao.SCTwRegressOrigIdent.rds
    Untracked:  output/merge.all.SCTwRegressOrigIdent.Harmony.rds
    Untracked:  output/merged.SCT.counts.matrix.rds
    Untracked:  output/merged.raw.counts.matrix.rds
    Untracked:  output/mergedObjects/
    Untracked:  output/pdfs/
    Untracked:  output/sampleQCrds/
    Untracked:  output/splitgpm_gsea_results/
    Untracked:  publish_stuff1.R
    Untracked:  publish_stuff2.R
    Untracked:  slurm-14911987.out

Unstaged changes:
    Deleted:    analysis/IntegrateAnalysis.afterFilter.HarmonyBatch.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.HarmonyBatchSampleIDindividual.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.NOHARMONYjustmerge.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.SCTregressBatchIndividual.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.SCTregressBatchIndividualHarmonyBatchindividual.Rmd
    Modified:   analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.1_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.8_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes1_minPCT0.2.Rmd
    Deleted:    analysis/RunscHCL_HarmonyBatchInd.Rmd

Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.


These are the previous versions of the repository in which changes were made to the R Markdown (analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.5_minPCT0.2.Rmd) and HTML (docs/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.5_minPCT0.2.html) files. If you've configured a remote Git repository (see ?wflow_git_remote), click on the hyperlinks in the table below to view the files as they were in that past version.

File Version Author Date Message
Rmd 42fd51c KLRhodes 2021-12-13 Fix supp files
Rmd fe7fae8 KLRhodes 2021-07-05 wflow_git_commit(c("analysis/Pseudobulk_HierarchicalClustering_Harmony.Batchindividual_ClusterRes*",
html 475b623 KLRhodes 2021-07-05 Build site.
html 7888de8 KLRhodes 2020-08-31 Build site.
Rmd 162da72 KLRhodes 2020-08-31 wflow_publish("analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.*")

library(Seurat)
library(Matrix)
library(dplyr)
library(edgeR)
library(limma)
library(reshape2)
library(ggplot2)
library(UpSetR)
library(tibble)

choose parameters (integration type, clustering res, min pct threshold)

f<- 'Harmony.Batchindividual'
pct<-0.2
res<- 'SCT_snn_res.0.5'
path<- here::here("output/DGELists/")
dge<- readRDS(paste0(path,"Pseudobulk_dge_",f, "_", res,"_minPCT",pct,".rds"))
cpm<- cpmByGroup(dge, group=dge$samples$cluster)
lcpm<- cpmByGroup(dge, group=dge$samples$cluster, log=TRUE)
hist(lcpm)

Version Author Date
7888de8 KLRhodes 2020-08-31
L<- mean(dge$samples$lib.size) *1e-6
M<- median(dge$samples$lib.size) *1e-6
genes.ribo <- grep('^RP',rownames(dge),value=T)
genes.no.ribo <- rownames(dge)[which(!(rownames(dge) %in% genes.ribo))]
dge$counts <- dge$counts[which(rownames(dge$counts) %in% genes.no.ribo),] #remove ribosomal genes
dge<- calcNormFactors(dge, method="TMM")

summary(dge$samples$norm.factors)
   Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
 0.7736  0.8998  0.9755  1.0174  1.0565  2.1383 
design<- model.matrix(~0+ dge$samples$cluster + dge$samples$batch + dge$samples$ind)
v<- voom(dge, design, plot=TRUE)

Version Author Date
7888de8 KLRhodes 2020-08-31
v
An object of class "EList"
$targets
                     group   lib.size norm.factors cluster  batch     ind
0.Batch1.SNG-NA18511     1   624484.3    1.0373235       0 Batch1 NA18511
0.Batch1.SNG-NA18858     1 77077818.7    1.0417138       0 Batch1 NA18858
0.Batch1.SNG-NA19160     1   491756.2    1.0074803       0 Batch1 NA19160
0.Batch2.SNG-NA18511     1  1017488.0    0.9970768       0 Batch2 NA18511
0.Batch2.SNG-NA18858     1 71713598.7    1.0374122       0 Batch2 NA18858
                                    Group
0.Batch1.SNG-NA18511 0.Batch1.SNG-NA18511
0.Batch1.SNG-NA18858 0.Batch1.SNG-NA18858
0.Batch1.SNG-NA19160 0.Batch1.SNG-NA19160
0.Batch2.SNG-NA18511 0.Batch2.SNG-NA18511
0.Batch2.SNG-NA18858 0.Batch2.SNG-NA18858
153 more rows ...

$E
        0.Batch1.SNG-NA18511 0.Batch1.SNG-NA18858 0.Batch1.SNG-NA19160
SAMD11              3.138692             1.469848             2.345910
NOC2L               6.777293             6.599711             6.623895
PLEKHN1             1.264223             1.734571             2.345910
HES4                5.656540             4.876733             4.111445
ISG15               4.808543             5.517413             5.906625
        0.Batch2.SNG-NA18511 0.Batch2.SNG-NA18858 0.Batch2.SNG-NA19160
SAMD11              2.675427            0.8414497             2.125949
NOC2L               6.341309            6.1443064             6.086778
PLEKHN1             2.434418            1.8159647             2.125949
HES4                6.030269            4.5392962             4.873183
ISG15               5.716454            5.3916126             5.888449
        0.Batch3.SNG-NA18511 0.Batch3.SNG-NA18858 0.Batch3.SNG-NA19160
SAMD11              2.324023            0.8580432             3.446319
NOC2L               6.430052            6.0721084             6.277720
PLEKHN1             1.965230            1.2667834             2.081323
HES4                5.793049            4.8552128             4.716409
ISG15               6.128539            5.4187155             5.958769
        1.Batch1.SNG-NA18511 1.Batch1.SNG-NA18858 1.Batch1.SNG-NA19160
SAMD11              2.781860             3.747049             2.864050
NOC2L               6.405942             6.047444             6.273040
PLEKHN1            -1.988214            -1.007839            -2.539672
HES4                9.438874             7.989341             8.843852
ISG15               5.363041             5.980846             5.615146
        1.Batch2.SNG-NA18511 1.Batch2.SNG-NA18858 1.Batch2.SNG-NA19160
SAMD11              2.752753             2.951904            2.6216420
NOC2L               6.078731             5.861258            6.1130558
PLEKHN1            -5.207249            -2.333498           -0.7608277
HES4                9.275370             7.619243            8.5222607
ISG15               5.697386             5.759259            5.6191695
        1.Batch3.SNG-NA18511 1.Batch3.SNG-NA18858 1.Batch3.SNG-NA19160
SAMD11              1.961524            3.6595341             3.977466
NOC2L               5.910084            5.9561511             6.052904
PLEKHN1            -2.224342           -0.8640278            -3.371262
HES4                8.757368            7.2074345             7.668342
ISG15               5.803564            5.5789156             5.755442
        10.Batch1.SNG-NA18511 10.Batch1.SNG-NA18858 10.Batch1.SNG-NA19160
SAMD11               4.904920             1.3686231              1.611808
NOC2L                7.226848             6.5631454              6.004125
PLEKHN1              2.097565             0.1462306              1.611808
HES4                 2.097565             5.6237641              7.444698
ISG15                6.185028             5.2194796              5.518699
        10.Batch2.SNG-NA18511 10.Batch2.SNG-NA18858 10.Batch2.SNG-NA19160
SAMD11               3.555120           -0.31459966             3.4115716
NOC2L                5.939784            6.00896694             6.2640144
PLEKHN1              2.707123           -0.07359156             0.2416466
HES4                 6.315932            5.82773951             5.7962355
ISG15                5.339391            4.98419194             4.6339640
        10.Batch3.SNG-NA18511 10.Batch3.SNG-NA18858 10.Batch3.SNG-NA19160
SAMD11              3.4499162             -2.083251             4.7410919
NOC2L               6.4593765              6.278693             6.6004936
PLEKHN1             0.7869512              1.376181            -0.3881911
HES4                5.8884892              5.135918             3.6992718
ISG15               5.4308074              6.188212             5.7615560
        11.Batch1.SNG-NA18511 11.Batch1.SNG-NA18858 11.Batch1.SNG-NA19160
SAMD11              3.1760213              1.888963              3.184850
NOC2L               6.2557485              6.412525              5.850302
PLEKHN1            -0.2834103              1.888963             -1.160925
HES4                9.5636470              8.396757              9.303621
ISG15               6.7052744              5.795853              6.317508
        11.Batch2.SNG-NA18511 11.Batch2.SNG-NA18858 11.Batch2.SNG-NA19160
SAMD11               3.287500              3.749486              3.415984
NOC2L                6.175025              3.749486              5.665460
PLEKHN1              0.965572              3.749486             -2.198726
HES4                 8.512466              8.273048              8.915667
ISG15                5.357889              6.556841              5.749642
        11.Batch3.SNG-NA18511 11.Batch3.SNG-NA18858 11.Batch3.SNG-NA19160
SAMD11              3.0439263              3.400259              4.225455
NOC2L               5.5941234              5.722187              5.853294
PLEKHN1             0.2365714              3.400259             -1.240519
HES4                7.8439017              8.155146              8.056397
ISG15               6.0179311              6.570184              6.136257
        12.Batch1.SNG-NA18511 12.Batch1.SNG-NA18858 12.Batch1.SNG-NA19160
SAMD11               5.848751             4.5393720              5.853125
NOC2L                6.592653             6.6985706              6.265320
PLEKHN1             -2.111251             0.6324814             -1.135560
HES4                 8.198226             5.3873689              8.081186
ISG15                4.734239             5.3873689              6.140565
        12.Batch2.SNG-NA18511 12.Batch2.SNG-NA18858 12.Batch2.SNG-NA19160
SAMD11               5.167884              1.363631             4.7123906
NOC2L                6.177142              6.007487             6.2973531
PLEKHN1             -1.111340              1.363631            -0.1455904
HES4                 7.913800              6.007487             7.4764614
ISG15                4.896155              5.270521             5.2119616
        12.Batch3.SNG-NA18511 12.Batch3.SNG-NA18858 12.Batch3.SNG-NA19160
SAMD11               4.836266              3.315688              6.399018
NOC2L                6.003003              5.431165              5.892739
PLEKHN1             -2.402139              1.730725             -1.401882
HES4                 7.357750              5.190157              7.133394
ISG15                4.653144              5.190157              4.747865
        13.Batch1.SNG-NA18511 13.Batch1.SNG-NA18858 13.Batch1.SNG-NA19160
SAMD11               2.271123           3.067434361              1.742686
NOC2L                6.020061           6.185129403              6.102942
PLEKHN1             -2.483765           0.008540672             -1.957754
HES4                 9.330417           8.125750856              8.676150
ISG15                5.860531           5.623250516              5.881450
        13.Batch2.SNG-NA18511 13.Batch2.SNG-NA18858 13.Batch2.SNG-NA19160
SAMD11               4.081243             2.5387459              3.993239
NOC2L                5.666205             6.2391856              6.315167
PLEKHN1              4.081243             0.2168178              3.993239
HES4                 7.251168             8.1651851              6.315167
ISG15                4.081243             5.3461009              3.993239
        13.Batch3.SNG-NA18858 14.Batch1.SNG-NA18511 14.Batch1.SNG-NA18858
SAMD11              2.5322300              5.065982              4.327362
NOC2L               5.9916616              5.959067              5.912325
PLEKHN1             0.2103019              2.258627              4.327362
HES4                8.1818454              3.843589              4.327362
ISG15               5.7021550              5.065982              5.912325
        14.Batch1.SNG-NA19160 14.Batch2.SNG-NA18511 14.Batch2.SNG-NA18858
SAMD11                4.04968              2.987145              3.737233
NOC2L                 4.04968              6.260163              6.059161
PLEKHN1               4.04968              2.987145              3.737233
HES4                  4.04968              4.946503              6.544588
ISG15                 4.04968              5.545140              6.059161
        14.Batch2.SNG-NA19160 14.Batch3.SNG-NA18511 14.Batch3.SNG-NA18858
SAMD11               5.488174              3.216760              3.917588
NOC2L                6.550101              6.426520              5.502551
PLEKHN1              1.977212              1.513477              3.917588
HES4                 5.147137              5.799828              6.724943
ISG15                5.147137              5.753596              5.502551
        14.Batch3.SNG-NA19160 15.Batch1.SNG-NA18511 15.Batch1.SNG-NA18858
SAMD11               4.960079              5.705990             4.3190354
NOC2L                6.372644              6.238100             6.1850181
PLEKHN1              1.940180             -1.412951             0.9498016
HES4                 5.156836              8.271797             7.6048353
ISG15                5.590434              5.094843             4.8566922
        15.Batch1.SNG-NA19160 15.Batch2.SNG-NA18511 15.Batch2.SNG-NA18858
SAMD11               4.868455              4.964905              4.067750
NOC2L                5.520532              5.788027              5.931688
PLEKHN1              2.061100              1.264465             -1.313072
HES4                 6.453418              8.699093              7.227379
ISG15                3.646063              1.264465              5.734961
        15.Batch2.SNG-NA19160 15.Batch3.SNG-NA18511 15.Batch3.SNG-NA18858
SAMD11               3.647037              2.084104             0.7259728
NOC2L                4.869429              5.254029             6.0835248
PLEKHN1              2.062074              2.084104             0.7259728
HES4                 6.920055              7.756530             7.3258857
ISG15                5.231999              5.990995             6.7032527
        15.Batch3.SNG-NA19160 16.Batch1.SNG-NA18511 16.Batch1.SNG-NA18858
SAMD11               3.377015              2.761433              2.625863
NOC2L                4.599407              5.931358              5.224901
PLEKHN1              1.792052              5.083361              4.913440
HES4                 6.435908              8.071288              6.926417
ISG15                4.113980              5.017773              8.121483
        16.Batch1.SNG-NA19160 16.Batch2.SNG-NA18511 16.Batch2.SNG-NA18858
SAMD11               4.245240              5.889975              3.845817
NOC2L                5.623752              5.153009              5.743937
PLEKHN1              5.742072              4.416044              4.634313
HES4                 6.814083              6.104100              7.127852
ISG15                6.084304              6.455572              8.023010
        16.Batch2.SNG-NA19160 16.Batch3.SNG-NA18511 16.Batch3.SNG-NA18858
SAMD11               4.349821              4.928228              2.930750
NOC2L                5.907039              5.435188              5.904755
PLEKHN1              4.264932              4.139732              5.332848
HES4                 6.420211              4.928228              6.943574
ISG15                4.775127              4.380741              8.288302
        16.Batch3.SNG-NA19160 17.Batch1.SNG-NA18511 17.Batch1.SNG-NA18858
SAMD11               5.423176            2.33381637              3.100060
NOC2L                5.511985            6.03425609              5.421988
PLEKHN1              3.969458            0.01188828              3.100060
HES4                 6.015751            7.23105680              5.907415
ISG15                5.278786            9.65754671              5.421988
        17.Batch1.SNG-NA19160 17.Batch2.SNG-NA18511 17.Batch2.SNG-NA19160
SAMD11              1.6766868             0.2434696            -0.8078316
NOC2L               5.7297981             6.1261127             5.7920813
PLEKHN1            -0.6452413             0.2434696            -0.8078316
HES4                6.9472157             6.0763597             6.8575044
ISG15               8.1588897             8.0700181             7.5185979
        17.Batch3.SNG-NA18511 17.Batch3.SNG-NA19160 2.Batch1.SNG-NA18511
SAMD11            -0.03310476            0.79402418            2.2563784
NOC2L              5.58160508            5.71050082            6.4543889
PLEKHN1           -0.03310476            0.05705858           -0.9586345
HES4               7.02217767            6.45508966            9.1634539
ISG15              8.07018305            8.38648122            5.7789750
        2.Batch1.SNG-NA18858 2.Batch1.SNG-NA19160 2.Batch2.SNG-NA18511
SAMD11              3.371089             3.347964             1.689570
NOC2L               6.146383             6.216891             6.145876
PLEKHN1             1.255612            -1.442113            -2.702747
HES4                7.277980             8.816453             8.803891
ISG15               5.601387             6.054186             5.847999
        2.Batch2.SNG-NA18858 2.Batch2.SNG-NA19160 2.Batch3.SNG-NA18511
SAMD11              2.732835             2.168768             2.184671
NOC2L               5.786350             6.170406             6.126751
PLEKHN1            -0.371502            -2.027630            -1.833251
HES4                6.812381             8.443707             8.169846
ISG15               6.051404             5.688904             5.803374
        2.Batch3.SNG-NA18858 2.Batch3.SNG-NA19160 3.Batch1.SNG-NA18511
SAMD11             1.6522064             4.053993            2.8900071
NOC2L              6.0445238             6.321567            6.2101960
PLEKHN1           -0.6697217            -2.840825            0.4218583
HES4               6.7978838             7.646010            5.4836345
ISG15              6.2727928             6.361299            6.4263597
        3.Batch1.SNG-NA18858 3.Batch1.SNG-NA19160 3.Batch2.SNG-NA18511
SAMD11              3.314066             3.219328            3.2494233
NOC2L               6.519180             6.247685            5.7109353
PLEKHN1             1.729103            -1.185427           -0.4059285
HES4                5.925500             5.927842            4.9516235
ISG15               6.802352             6.621343            6.4545378
        3.Batch2.SNG-NA18858 3.Batch2.SNG-NA19160 3.Batch3.SNG-NA18511
SAMD11              4.442953             2.984379           2.97513203
NOC2L               5.580457             5.967890           6.02099904
PLEKHN1             2.121025            -0.234045          -0.04116978
HES4                3.705987             5.197372           3.81228156
ISG15               6.208488             6.316998           6.22901935
        3.Batch3.SNG-NA18858 3.Batch3.SNG-NA19160 4.Batch1.SNG-NA18511
SAMD11              2.342371             3.308837           4.64058645
NOC2L               5.801803             6.135238           6.43920657
PLEKHN1             2.342371            -1.269431           0.07580184
HES4                5.149726             4.920394           7.03387116
ISG15               6.865933             6.403780           6.03773380
        4.Batch1.SNG-NA18858 4.Batch1.SNG-NA19160 4.Batch2.SNG-NA18511
SAMD11             4.1871834             3.048785            5.1585532
NOC2L              6.5606418             6.254799            6.2580889
PLEKHN1            0.7277518            -1.373747           -0.4561566
HES4               6.8362763             6.582387            6.3120277
ISG15              4.8152147             5.112753            5.8836934
        4.Batch2.SNG-NA18858 4.Batch2.SNG-NA19160 4.Batch3.SNG-NA18511
SAMD11              2.596729             3.410961            2.4756421
NOC2L               5.766654             6.181896            6.0794637
PLEKHN1             2.596729            -1.486280           -0.1873229
HES4                5.404084             6.501269            4.4945012
ISG15               4.918657             4.943336            4.6706581
        4.Batch3.SNG-NA18858 4.Batch3.SNG-NA19160 5.Batch1.SNG-NA18511
SAMD11              1.904391             4.451682            3.9378483
NOC2L               6.659279             6.030057            6.2301309
PLEKHN1             1.904391            -2.741433            0.3771334
HES4                5.811282             5.590977            8.2413195
ISG15               5.074316             4.232026            5.5709051
        5.Batch1.SNG-NA18858 5.Batch1.SNG-NA19160 5.Batch2.SNG-NA18511
SAMD11              4.491454            1.8299187            2.9613083
NOC2L               6.055807            6.0645800            6.0063548
PLEKHN1             1.258794           -0.3717152            0.5956588
HES4                5.240646            6.6124184            6.6450885
ISG15               5.731281            5.6595036            5.2745975
        5.Batch2.SNG-NA18858 5.Batch2.SNG-NA19160 5.Batch3.SNG-NA18511
SAMD11              3.147236            3.0621076            2.2925337
NOC2L               5.639475            5.7920754            5.9991685
PLEKHN1             1.416052            0.6104116            0.4180646
HES4                5.523740            4.7756142            5.0289947
ISG15               6.136331            5.3715717            5.5704144
        5.Batch3.SNG-NA18858 5.Batch3.SNG-NA19160 6.Batch1.SNG-NA18511
SAMD11              2.512142            3.1373449            4.7206961
NOC2L               5.710922            6.0961633            6.0154881
PLEKHN1             2.222636            0.8453183            0.8492108
HES4                4.983448            5.2655485            7.0815227
ISG15               6.018495            5.7705874            6.9728620
        6.Batch1.SNG-NA18858 6.Batch1.SNG-NA19160 6.Batch2.SNG-NA18511
SAMD11              2.725273             4.488108             4.579490
NOC2L               5.760897             5.937718             5.942410
PLEKHN1             5.447739             3.376215             1.132604
HES4                6.812736             7.025645             7.144364
ISG15               6.778384             7.517415             6.783314
        6.Batch2.SNG-NA18858 6.Batch2.SNG-NA19160 6.Batch3.SNG-NA18511
SAMD11              4.369502             3.789253            4.9796225
NOC2L               5.287039             5.771975            6.0276697
PLEKHN1             3.521505             1.467325            0.7085187
HES4                6.625841             6.756246            5.7050465
ISG15               5.954464             7.131645            6.2678222
        6.Batch3.SNG-NA18858 6.Batch3.SNG-NA19160 7.Batch1.SNG-NA18511
SAMD11              3.334450            4.4266903             3.718819
NOC2L               5.812497            5.9923199             6.151778
PLEKHN1             2.112058            0.1496654             2.981853
HES4                7.213596            6.4079655             6.606344
ISG15               7.241341            7.0967132             5.303781
        7.Batch1.SNG-NA18858 7.Batch1.SNG-NA19160 7.Batch2.SNG-NA18511
SAMD11              1.860589             2.202334             3.227946
NOC2L               6.238745             5.661766             6.332282
PLEKHN1             1.098748             0.617372             2.490980
HES4                5.538082             4.076804             5.153945
ISG15               5.110462             6.109225             4.365449
        7.Batch2.SNG-NA18858 7.Batch2.SNG-NA19160 7.Batch3.SNG-NA18511
SAMD11              1.070192             3.885427             2.816636
NOC2L               5.884888             6.141767             6.316902
PLEKHN1             1.597821             0.715502             2.028141
HES4                5.643396             5.013183             5.708260
ISG15               5.347403             5.759896             5.666741
        7.Batch3.SNG-NA18858 7.Batch3.SNG-NA19160 8.Batch1.SNG-NA18511
SAMD11             0.9598028            2.8576628             2.707524
NOC2L              5.7741038            6.0609464             5.889967
PLEKHN1            1.3650593            0.1946978            -2.964902
HES4               5.2797800            4.7995599             9.128846
ISG15              5.5398831            5.7896444             4.935965
        8.Batch1.SNG-NA18858 8.Batch1.SNG-NA19160 8.Batch2.SNG-NA18511
SAMD11             2.5725796            3.0196698             2.910340
NOC2L              5.6478677            5.9582693             5.894180
PLEKHN1           -0.2347754           -0.8872208            -3.747871
HES4               7.7367682            8.6278219             8.975576
ISG15              4.8945077            4.8941389             5.209231
        8.Batch2.SNG-NA18858 8.Batch2.SNG-NA19160 8.Batch3.SNG-NA18511
SAMD11              2.352117             1.509119             2.128847
NOC2L               5.393145             5.583467             5.698313
PLEKHN1            -1.348322            -2.191320            -3.156555
HES4                7.065306             8.344927             8.441962
ISG15               4.801425             4.774464             5.741290
        8.Batch3.SNG-NA18858 8.Batch3.SNG-NA19160 9.Batch1.SNG-NA18511
SAMD11             3.4885531             3.896876            4.0997227
NOC2L              6.0387501             5.771345            6.5538986
PLEKHN1            0.6811981            -1.594977           -0.5441335
HES4               6.5140881             7.557308            6.6357756
ISG15              5.8906515             5.299841            3.9794285
        9.Batch1.SNG-NA18858 9.Batch1.SNG-NA19160 9.Batch2.SNG-NA18511
SAMD11              3.717622            3.1891642           0.01814573
NOC2L               6.440088            6.6459964           5.30354795
PLEKHN1             1.395694           -0.2991222           0.01814573
HES4                5.919256            6.7220120           6.73239125
ISG15               6.821959            2.7207773           4.10560857
        9.Batch2.SNG-NA18858 9.Batch2.SNG-NA19160 9.Batch3.SNG-NA18511
SAMD11              5.938852            2.7629643             3.440982
NOC2L               5.201886            6.1343611             5.969361
PLEKHN1             3.616923            0.7961311             1.325505
HES4                6.424278            6.2703902             5.295131
ISG15               3.616923            2.5461529             4.495430
        9.Batch3.SNG-NA18858 9.Batch3.SNG-NA19160
SAMD11              2.305067            3.9919915
NOC2L               5.764498            6.2076266
PLEKHN1             2.305067           -2.7494755
HES4                3.890029            5.5405434
ISG15               3.890029            0.9509643
10910 more rows ...

$weights
          [,1]      [,2]      [,3]      [,4]      [,5]      [,6]      [,7]
[1,] 0.6587441  8.587138 0.5843784 0.8252667  7.769479 0.7249437  3.799485
[2,] 4.3135933 25.043467 3.6375757 5.0410984 22.969680 4.2885870 13.012541
[3,] 0.4158378 10.831053 0.3324969 0.6074312 10.838554 0.4758115  2.950604
[4,] 3.0874766 18.280112 2.4908495 3.5619379 16.850399 2.8911868  9.222214
[5,] 3.0762373 22.334402 2.7058661 3.5541463 20.601241 3.1051165 10.839747
          [,8]     [,9]      [,10]     [,11]      [,12]      [,13]     [,14]
[1,]  7.869231 2.433157  6.5881252 1.1230348  5.5203708  6.8678532  2.092545
[2,] 24.204796 8.860101 13.7453542 4.6635647 11.4722013 14.2125769  6.577533
[3,] 10.461609 1.406987  0.4825516 0.2080015  0.3325939  0.6177012  0.301547
[4,] 15.878245 5.472454 25.3591693 9.1653480 20.0255896 26.3480912 11.909890
[5,] 22.633563 7.221276 11.8636018 4.4249882  9.8924002 12.3421086  6.338589
          [,15]      [,16]     [,17]      [,18]     [,19]    [,20]     [,21]
[1,]  4.1271560  5.4368576 0.8322290  3.6979367 0.2441284 2.303058 0.3081592
[2,]  9.3931155 12.4485151 4.1371662  9.1224045 1.7558841 9.271693 2.1270991
[3,]  0.2766965  0.3968922 0.2080015  0.2291551 0.2080015 2.134896 0.2080015
[4,] 16.6172590 20.5551341 7.4211944 14.4883886 1.1296832 6.909100 1.2389702
[5,]  8.0553047 11.2361737 4.2243646  8.1921537 0.8704064 7.814890 1.1010931
         [,22]     [,23]     [,24]     [,25]    [,26]     [,27]     [,28]
[1,] 0.4459915  2.734088 0.4990666 0.7552570 1.099570 0.6450228 1.2196079
[2,] 3.0859269 10.458252 3.1148382 4.7930294 6.828974 3.9599959 3.3343653
[3,] 0.2210935  2.906349 0.2188338 0.3140179 1.105092 0.2489624 0.2394964
[4,] 2.4858189  7.964700 2.3061704 3.1711667 4.079742 2.5151600 9.2129528
[5,] 2.0792385  8.935351 2.1343222 3.3994914 5.958126 2.9338926 3.5507134
         [,29]      [,30]     [,31]     [,32]      [,33]     [,34]     [,35]
[1,] 0.3037654  3.6588423 0.5343900 0.2080015  2.8387822 0.7300130 0.2080015
[2,] 1.1749407  7.3201048 1.9489119 0.3944973  5.7316445 2.7044948 0.4793473
[3,] 0.2080015  0.6524826 0.2080015 0.2080015  0.5272902 0.2080015 0.2080015
[4,] 3.9591241 15.2094495 6.0563773 1.8380514 12.6805498 6.6865864 1.7856515
[5,] 1.7947740  7.7732217 2.1570739 0.5451580  6.1697806 3.0393174 0.7369443
          [,36]     [,37]     [,38]     [,39]     [,40]     [,41]     [,42]
[1,]  4.3273543 4.6921055 1.1195769 3.4085503  5.225845 0.6428270 2.2589629
[2,]  8.6882836 7.1765901 2.7595744 5.1166806  7.851157 1.8274189 3.2724494
[3,]  0.9141361 0.3194983 0.2080015 0.2080015  0.431199 0.2080015 0.2080015
[4,] 15.8044594 9.7920693 3.5088251 6.8803173 10.632415 2.5971500 4.6191543
[5,]  9.6598469 4.8165233 2.0547341 3.2904803  5.412747 1.1516903 2.1839577
         [,43]     [,44]     [,45]      [,46]     [,47]      [,48]     [,49]
[1,] 4.5641440 0.5143735 3.3006544  2.9261643 1.4891881  2.5565736 0.2080015
[2,] 7.4013625 1.5444793 5.2624448  7.8033063 5.6499510  6.4867127 0.4359909
[3,] 0.3343099 0.2080015 0.2108786  0.5691947 0.6824614  0.4120908 0.2080015
[4,] 8.9417868 1.8710096 6.1320782 13.4532630 9.5033688 10.9997053 1.4556132
[5,] 5.3517147 1.0777190 3.6188554  5.5871602 4.5664421  4.5323694 0.2738797
         [,50]     [,51]     [,52]     [,53]     [,54]     [,55]    [,56]
[1,] 0.4793482 0.2080015 0.4600711 0.5121899 0.2080015 0.2487624 1.730523
[2,] 2.8241916 0.4314390 2.8993987 1.1815882 0.3757571 0.4376436 3.172458
[3,] 0.3156964 0.2080015 0.2813270 0.2246075 0.2080015 0.2080015 0.681648
[4,] 5.2890046 1.2384215 4.6159670 0.9407158 0.2744911 0.3360564 2.859136
[5,] 2.2844289 0.2740604 2.5290024 0.7670135 0.3374574 0.3202842 2.542607
         [,57]     [,58]    [,59]     [,60]    [,61]     [,62]    [,63]
[1,] 0.2080015 1.9929490 6.141099 0.2080015 4.624573 2.7303654 2.884054
[2,] 0.4339925 3.2197263 9.919958 0.4152339 7.505168 4.8505100 5.972016
[3,] 0.2167931 0.6784974 3.320939 0.2080015 2.308673 0.4373443 1.325870
[4,] 0.3153412 2.7067212 7.985575 0.2498984 5.422698 9.1714728 9.771311
[5,] 0.3921263 2.6108008 8.642884 0.4062111 6.446268 3.2541497 4.859487
         [,64]     [,65]     [,66]     [,67]     [,68]     [,69]     [,70]
[1,] 0.4786378 0.5848768  3.244416 0.4226024 0.3836692 0.5354967 0.4573445
[2,] 1.0407639 1.5614711  6.765571 0.8906886 0.9833042 2.0040299 1.0966775
[3,] 0.2080015 0.2080015  2.085504 0.2080015 0.2080015 0.2802513 0.2080015
[4,] 2.7764653 3.6544339 10.851010 2.5578589 2.4824552 3.1860434 2.4395324
[5,] 0.5805583 0.8036459  5.625121 0.5171138 0.6039863 1.5814490 0.6684977
        [,71]    [,72]    [,73]     [,74]     [,75]    [,76]    [,77]    [,78]
[1,] 2.141213 2.536088 2.981907 0.7054845 0.7972339 2.329382 0.909571 0.874213
[2,] 3.367408 4.630409 4.387778 1.5759442 2.2472641 3.361670 2.214840 2.564768
[3,] 2.024516 4.601827 2.642694 0.8080964 2.5738744 2.316917 0.943660 2.549410
[4,] 5.433527 6.350653 6.353622 2.8545938 3.1170374 5.051530 2.995236 2.995930
[5,] 3.907704 6.250236 5.127412 2.0167330 3.0755193 3.971508 2.774660 3.631510
        [,79]     [,80]     [,81]     [,82]     [,83]     [,84]     [,85]
[1,] 2.024206 0.3198359 0.2080015 0.4446973 0.2609945 0.4231984 0.2803674
[2,] 3.216193 3.0798894 0.6114562 3.6683070 2.6509157 3.5359717 2.9601297
[3,] 1.814655 0.2093324 0.2080015 0.2514421 0.2080015 0.2795738 0.2080015
[4,] 4.030213 4.5936682 0.9177950 5.1304646 3.8436653 4.9829980 3.6705814
[5,] 4.023942 6.0559021 2.3852717 7.1843735 5.1988330 7.0183933 6.1738920
         [,86]      [,87]     [,88]      [,89]      [,90]      [,91]      [,92]
[1,] 0.5655783  4.0358702 0.6122809  5.6255623  4.4301697  2.0270423  3.5762036
[2,] 4.7487802 11.0242631 3.7344984 13.0851404 11.7138590  7.4817829  9.6894290
[3,] 0.3335675  0.4688847 0.2080015  0.6470125  0.6323808  0.5423601  0.4247085
[4,] 5.5445755 18.2631591 6.8760549 20.5488384 19.4632939 11.8631233 15.3956433
[5,] 9.1531619  9.8483790 3.7738650 11.8200657 10.5466863  7.5897151  8.7138990
          [,93]     [,94]     [,95]      [,96]     [,97]     [,98]     [,99]
[1,]  4.0682805 0.6040924  2.743424  4.5187826 0.6469616  6.799996 3.1486342
[2,] 11.5757158 3.9615386  8.110215  9.9658911 3.0674144 12.781135 7.6409073
[3,]  0.5161951 0.2080015  0.271301  0.9506118 0.3086999  1.753181 0.6693673
[4,] 17.1966847 6.2684923 11.760628  8.4199874 2.1383248 10.362096 6.3275657
[5,] 10.8759919 4.3186180  7.600788 10.4964578 3.8707739 13.492559 8.1446330
        [,100]    [,101]     [,102]    [,103]    [,104]    [,105]    [,106]
[1,] 0.2418022  4.982213  3.9636269 0.2146084  5.707824 2.6302508 0.5771402
[2,] 1.0553311 10.147442  9.5588262 0.9710074 11.678328 6.1694818 2.7602555
[3,] 0.2080015  1.202271  0.8642126 0.2080015  1.380097 0.2945989 0.2080015
[4,] 0.6072277  8.118405  7.0688840 0.4527203  8.343652 6.4895819 2.5748142
[5,] 1.6672540 10.807187 10.5822239 1.7066073 12.926899 3.7742961 1.9004922
        [,107]    [,108]    [,109]     [,110]    [,111]    [,112]     [,113]
[1,]  7.313648 1.3674333 0.2304960  5.3724396 2.5363450 0.2910128  6.1449248
[2,] 13.152674 3.9201214 0.9108757 10.3972645 6.3215457 1.4712261 11.9920165
[3,]  1.210921 0.2080015 0.2080015  0.8335916 0.3044335 0.2080015  0.9487866
[4,] 12.969798 4.2031179 0.8170940 10.2863765 5.7646316 0.9633160 10.5832774
[5,]  9.433666 2.4947596 0.5705278  7.2714321 4.1974323 0.9375251  8.9659590
        [,114]    [,115]    [,116]   [,117]   [,118]   [,119]    [,120]
[1,] 2.5732660 1.1670013 3.3321101 3.372442 2.905708 3.996730  6.034138
[2,] 6.4419187 4.5523512 7.7542931 8.307511 8.190047 8.892964 13.029161
[3,] 0.5358885 0.6489274 0.7115043 1.044922 2.310630 1.183572  2.377239
[4,] 6.8600365 4.2800064 7.7152430 8.815727 7.863385 8.890306 12.283663
[5,] 5.4702103 4.5017429 6.7139683 7.239514 8.172758 7.844046 12.094490
        [,121]    [,122]    [,123]    [,124]    [,125]    [,126]    [,127]
[1,] 0.8746361  5.437274  4.667359 0.9436474 3.3321374  5.312832 0.5426446
[2,] 4.0759616 11.498286  7.566451 2.6869020 5.3439359  8.392817 1.6776752
[3,] 0.5611363  1.797855  1.589554 0.5881908 0.7695679  2.329926 0.4263396
[4,] 3.2584493 10.238616 10.487333 3.5207485 7.3429899 11.540733 2.5468104
[5,] 4.3438012 10.711149  9.282867 4.0505924 6.8489799 10.274224 2.8838701
       [,128]    [,129]    [,130]    [,131]    [,132]   [,133]    [,134]
[1,] 4.906621  4.690456 0.7208601  8.402172 0.3541681 2.854388 0.5264401
[2,] 7.436713  7.988575 2.4108431 12.185855 2.1437669 9.490563 2.7526030
[3,] 1.838781  1.786653 0.5083354  3.299111 0.2080015 2.952120 0.2210246
[4,] 9.808512  9.821654 2.7852738 13.894474 1.7503882 7.747257 2.1855487
[5,] 9.251173 10.255212 3.8924813 15.325287 1.3077562 8.623161 1.9743526
        [,135]    [,136]    [,137]    [,138]    [,139]    [,140]    [,141]
[1,] 0.3893749  4.735203 0.9900201 1.2410678  3.260434 1.2893143  3.194116
[2,] 2.3556930 13.570135 4.0969404 5.3533541 11.100627 5.0859999  8.164818
[3,] 0.2201520  5.595792 0.4245559 0.5206975  3.600769 0.4716777  0.276699
[4,] 1.9934519 11.382466 3.2993097 3.9330690  8.124000 3.4280556 15.364851
[5,] 1.5322707 12.523126 3.1001201 4.2384504 10.652753 4.0396019  6.398980
        [,142]     [,143]     [,144]    [,145]     [,146]     [,147]    [,148]
[1,] 0.6215747  2.8507008  3.7922673 0.9739062  2.3586125  3.0353457 0.3454113
[2,] 3.1769970  6.8903612  9.3386884 4.2766794  5.8384105  8.1830512 2.1983235
[3,] 0.2080015  0.2144732  0.4022401 0.2524875  0.2080015  0.2776995 0.2080015
[4,] 6.7875551 12.7021814 17.3764770 8.6299043 11.2267058 13.8394955 4.0259093
[5,] 2.8636735  5.3315572  7.5034786 3.7699647  4.4474726  6.8141108 2.0481007
        [,149]   [,150]    [,151]    [,152]    [,153]    [,154]    [,155]
[1,] 1.6834395 1.451467 0.3757177 4.7933313 0.8696654 0.2080015 3.2600460
[2,] 4.9254779 4.117287 1.9341539 9.6632011 3.1036773 0.4856851 7.2767409
[3,] 0.2080015 0.270927 0.2103745 0.9950778 0.2272734 0.2080015 0.6793922
[4,] 8.7711245 4.539112 1.8183528 9.7506262 3.3779583 0.4642358 7.3879275
[5,] 3.9212741 1.465926 0.5836596 4.5117504 0.8926882 0.2080015 3.1281272
        [,156]    [,157]    [,158]
[1,] 0.9652068 0.2243569 3.2504393
[2,] 3.4678662 0.9942515 7.6310988
[3,] 0.2262572 0.2080015 0.6142165
[4,] 3.2502862 0.7209098 6.7372140
[5,] 1.2356906 0.3870356 3.4842327
10910 more rows ...

$design
  dge$samples$cluster0 dge$samples$cluster1 dge$samples$cluster10
1                    1                    0                     0
2                    1                    0                     0
3                    1                    0                     0
4                    1                    0                     0
5                    1                    0                     0
  dge$samples$cluster11 dge$samples$cluster12 dge$samples$cluster13
1                     0                     0                     0
2                     0                     0                     0
3                     0                     0                     0
4                     0                     0                     0
5                     0                     0                     0
  dge$samples$cluster14 dge$samples$cluster15 dge$samples$cluster16
1                     0                     0                     0
2                     0                     0                     0
3                     0                     0                     0
4                     0                     0                     0
5                     0                     0                     0
  dge$samples$cluster17 dge$samples$cluster2 dge$samples$cluster3
1                     0                    0                    0
2                     0                    0                    0
3                     0                    0                    0
4                     0                    0                    0
5                     0                    0                    0
  dge$samples$cluster4 dge$samples$cluster5 dge$samples$cluster6
1                    0                    0                    0
2                    0                    0                    0
3                    0                    0                    0
4                    0                    0                    0
5                    0                    0                    0
  dge$samples$cluster7 dge$samples$cluster8 dge$samples$cluster9
1                    0                    0                    0
2                    0                    0                    0
3                    0                    0                    0
4                    0                    0                    0
5                    0                    0                    0
  dge$samples$batchBatch2 dge$samples$batchBatch3 dge$samples$indNA18858
1                       0                       0                      0
2                       0                       0                      1
3                       0                       0                      0
4                       1                       0                      0
5                       1                       0                      1
  dge$samples$indNA19160
1                      0
2                      0
3                      1
4                      0
5                      0
153 more rows ...

1 v all contrasts

fit<- lmFit(v,design)
nclust<- length(unique(dge$samples$cluster))
contrasts<- NULL
for (i in 1:nclust){
    c<- c(rep(-1,nclust),0,0,0,0)
    c[i]<- nclust-1
    
    contrasts<- cbind(contrasts, c)
}
contrasts
       c  c  c  c  c  c  c  c  c  c  c  c  c  c  c  c  c  c
 [1,] 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [2,] -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [3,] -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [4,] -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [5,] -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [6,] -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [7,] -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [8,] -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
 [9,] -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1 -1
[10,] -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1 -1
[11,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1 -1
[12,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1 -1
[13,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1 -1
[14,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1 -1
[15,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1 -1
[16,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1 -1
[17,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17 -1
[18,] -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 17
[19,]  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0
[20,]  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0
[21,]  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0
[22,]  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0
#first, testing all pairwise cluster comparisons. 
fit<- contrasts.fit(fit, contrasts= contrasts)
efit<- eBayes(fit)
plotSA(efit)

Version Author Date
475b623 KLRhodes 2021-07-05
summary(decideTests(efit))
          c    c    c    c    c    c    c    c    c    c    c    c    c    c
Down   3750 3515 3003 2004 3949 2029 3079 1365 2784 2278 3530 2713 2403 2065
NotSig 2813 4002 4701 6910 3840 6607 3965 8035 5121 5996 4046 5138 5977 5783
Up     4352 3398 3211 2001 3126 2279 3871 1515 3010 2641 3339 3064 2535 3067
          c    c    c    c
Down   2889 3194 3141 2776
NotSig 4709 3841 4775 5519
Up     3317 3880 2999 2620

output all OneVall cluster comparisons

output.list<- list()
for (i in 1:nclust){
  ta<- topTable(efit, coef=i,n=nrow(fit))
  output.list[[i]]<- ta
}

listnames<- c(paste0("Cluster", unique(dge$samples$cluster)))
names(output.list)<- as.vector(listnames)
#add cluster number to colnames
for (i in 1:nclust){
  d<- names(output.list[i])
  colnames(output.list[[i]])<- paste(d, colnames(output.list[[i]]), sep=".")
}

all<- left_join(rownames_to_column(output.list[[1]]), rownames_to_column(output.list[[2]]), by= c("rowname" = "rowname"))
for (i in 3:nclust){
  all<- left_join(all, rownames_to_column(output.list[[i]]), by= c("rowname" = "rowname"))
}

colnames(all)[1]<- "gene"

write.csv(all, "/project2/gilad/katie/Pilot_HumanEBs/Embryoid_Body_Pilot_Workflowr/output/NEW_Pseudobulk_Limma_res0.5_OnevAllTopTables.csv")
sessionInfo()
R version 3.6.1 (2019-07-05)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Scientific Linux 7.4 (Nitrogen)

Matrix products: default
BLAS/LAPACK: /software/openblas-0.2.19-el7-x86_64/lib/libopenblas_haswellp-r0.2.19.so

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] tibble_3.1.5    UpSetR_1.4.0    ggplot2_3.3.5   reshape2_1.4.4 
 [5] edgeR_3.28.1    limma_3.42.2    dplyr_1.0.2     Matrix_1.2-18  
 [9] Seurat_3.2.0    workflowr_1.6.2

loaded via a namespace (and not attached):
  [1] Rtsne_0.15            colorspace_2.0-2      deldir_0.1-28        
  [4] ellipsis_0.3.2        ggridges_0.5.2        rprojroot_2.0.2      
  [7] fs_1.4.2              spatstat.data_1.4-3   leiden_0.3.3         
 [10] listenv_0.8.0         npsurv_0.4-0          ggrepel_0.9.0        
 [13] fansi_0.5.0           codetools_0.2-16      splines_3.6.1        
 [16] lsei_1.2-0            knitr_1.29            polyclip_1.10-0      
 [19] jsonlite_1.7.2        ica_1.0-2             cluster_2.1.0        
 [22] png_0.1-7             uwot_0.1.10           shiny_1.5.0          
 [25] sctransform_0.2.1     compiler_3.6.1        httr_1.4.2           
 [28] fastmap_1.0.1         lazyeval_0.2.2        later_1.1.0.1        
 [31] htmltools_0.5.0       tools_3.6.1           rsvd_1.0.3           
 [34] igraph_1.2.6          gtable_0.3.0          glue_1.4.2           
 [37] RANN_2.6.1            rappdirs_0.3.3        Rcpp_1.0.6           
 [40] spatstat_1.64-1       vctrs_0.3.8           ape_5.4-1            
 [43] nlme_3.1-140          lmtest_0.9-37         xfun_0.16            
 [46] stringr_1.4.0         globals_0.12.5        mime_0.9             
 [49] miniUI_0.1.1.1        lifecycle_1.0.1       irlba_2.3.3          
 [52] goftest_1.2-2         future_1.18.0         MASS_7.3-51.4        
 [55] zoo_1.8-8             scales_1.1.1          promises_1.1.1       
 [58] spatstat.utils_1.17-0 parallel_3.6.1        RColorBrewer_1.1-2   
 [61] yaml_2.2.1            reticulate_1.20       pbapply_1.4-2        
 [64] gridExtra_2.3         rpart_4.1-15          stringi_1.5.3        
 [67] highr_0.8             rlang_0.4.11          pkgconfig_2.0.3      
 [70] evaluate_0.14         lattice_0.20-38       ROCR_1.0-11          
 [73] purrr_0.3.4           tensor_1.5            patchwork_1.1.1      
 [76] htmlwidgets_1.5.1     cowplot_1.1.1         tidyselect_1.1.0     
 [79] here_0.1-11           RcppAnnoy_0.0.18      plyr_1.8.6           
 [82] magrittr_2.0.1        R6_2.5.1              generics_0.1.0       
 [85] pillar_1.6.3          whisker_0.4           withr_2.4.2          
 [88] mgcv_1.8-28           fitdistrplus_1.0-14   survival_3.2-3       
 [91] abind_1.4-5           future.apply_1.6.0    crayon_1.4.1         
 [94] KernSmooth_2.23-15    utf8_1.2.2            plotly_4.9.2.1       
 [97] rmarkdown_2.3         locfit_1.5-9.4        grid_3.6.1           
[100] data.table_1.13.4     git2r_0.26.1          digest_0.6.28        
[103] xtable_1.8-4          tidyr_1.1.0           httpuv_1.5.4         
[106] munsell_0.5.0         viridisLite_0.4.0    

sessionInfo()
R version 3.6.1 (2019-07-05)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Scientific Linux 7.4 (Nitrogen)

Matrix products: default
BLAS/LAPACK: /software/openblas-0.2.19-el7-x86_64/lib/libopenblas_haswellp-r0.2.19.so

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] tibble_3.1.5    UpSetR_1.4.0    ggplot2_3.3.5   reshape2_1.4.4 
 [5] edgeR_3.28.1    limma_3.42.2    dplyr_1.0.2     Matrix_1.2-18  
 [9] Seurat_3.2.0    workflowr_1.6.2

loaded via a namespace (and not attached):
  [1] Rtsne_0.15            colorspace_2.0-2      deldir_0.1-28        
  [4] ellipsis_0.3.2        ggridges_0.5.2        rprojroot_2.0.2      
  [7] fs_1.4.2              spatstat.data_1.4-3   leiden_0.3.3         
 [10] listenv_0.8.0         npsurv_0.4-0          ggrepel_0.9.0        
 [13] fansi_0.5.0           codetools_0.2-16      splines_3.6.1        
 [16] lsei_1.2-0            knitr_1.29            polyclip_1.10-0      
 [19] jsonlite_1.7.2        ica_1.0-2             cluster_2.1.0        
 [22] png_0.1-7             uwot_0.1.10           shiny_1.5.0          
 [25] sctransform_0.2.1     compiler_3.6.1        httr_1.4.2           
 [28] fastmap_1.0.1         lazyeval_0.2.2        later_1.1.0.1        
 [31] htmltools_0.5.0       tools_3.6.1           rsvd_1.0.3           
 [34] igraph_1.2.6          gtable_0.3.0          glue_1.4.2           
 [37] RANN_2.6.1            rappdirs_0.3.3        Rcpp_1.0.6           
 [40] spatstat_1.64-1       vctrs_0.3.8           ape_5.4-1            
 [43] nlme_3.1-140          lmtest_0.9-37         xfun_0.16            
 [46] stringr_1.4.0         globals_0.12.5        mime_0.9             
 [49] miniUI_0.1.1.1        lifecycle_1.0.1       irlba_2.3.3          
 [52] goftest_1.2-2         future_1.18.0         MASS_7.3-51.4        
 [55] zoo_1.8-8             scales_1.1.1          promises_1.1.1       
 [58] spatstat.utils_1.17-0 parallel_3.6.1        RColorBrewer_1.1-2   
 [61] yaml_2.2.1            reticulate_1.20       pbapply_1.4-2        
 [64] gridExtra_2.3         rpart_4.1-15          stringi_1.5.3        
 [67] highr_0.8             rlang_0.4.11          pkgconfig_2.0.3      
 [70] evaluate_0.14         lattice_0.20-38       ROCR_1.0-11          
 [73] purrr_0.3.4           tensor_1.5            patchwork_1.1.1      
 [76] htmlwidgets_1.5.1     cowplot_1.1.1         tidyselect_1.1.0     
 [79] here_0.1-11           RcppAnnoy_0.0.18      plyr_1.8.6           
 [82] magrittr_2.0.1        R6_2.5.1              generics_0.1.0       
 [85] pillar_1.6.3          whisker_0.4           withr_2.4.2          
 [88] mgcv_1.8-28           fitdistrplus_1.0-14   survival_3.2-3       
 [91] abind_1.4-5           future.apply_1.6.0    crayon_1.4.1         
 [94] KernSmooth_2.23-15    utf8_1.2.2            plotly_4.9.2.1       
 [97] rmarkdown_2.3         locfit_1.5-9.4        grid_3.6.1           
[100] data.table_1.13.4     git2r_0.26.1          digest_0.6.28        
[103] xtable_1.8-4          tidyr_1.1.0           httpuv_1.5.4         
[106] munsell_0.5.0         viridisLite_0.4.0