Last updated: 2021-07-05

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.


The R Markdown file has unstaged changes. To know which version of the R Markdown file created these results, you'll want to first commit it to the Git repo. If you're still working on the analysis, you can ignore this warning. When you're finished, you can run wflow_publish to commit the R Markdown file and build the HTML.

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.

Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.

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 c8767ac. 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:    output/.Rhistory

Untracked files:
    Untracked:  GSE122380_raw_counts.txt.gz
    Untracked:  UTF1_plots.Rmd
    Untracked:  analysis/IntegrateReference_SCTregressCaoPlusScHCL_JustEarlyEcto.Rmd
    Untracked:  analysis/IntegrateReference_SCTregressCaoPlusScHCL_JustEndo.Rmd
    Untracked:  analysis/IntegrateReference_SCTregressCaoPlusScHCL_JustMeso.Rmd
    Untracked:  analysis/IntegrateReference_SCTregressCaoPlusScHCL_JustNeuralCrest.Rmd
    Untracked:  analysis/IntegrateReference_SCTregressCaoPlusScHCL_JustNeuron.Rmd
    Untracked:  analysis/IntegrateReference_SCTregressCaoPlusScHCL_JustPluri.Rmd
    Untracked:  analysis/OLD/
    Untracked:  analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.8_minPCT0.2.Rmd
    Untracked:  analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes1_minPCT0.2.Rmd
    Untracked:  analysis/Pseudobulk_VariancePartition_Harmony.Batchindividual_ClusterRes0.1_byCluster.Rmd
    Untracked:  analysis/RefInt_ComparingFulltoPartialIntegrationAnnotations.Rmd
    Untracked:  analysis/ReferenceAnn_DE.Rmd
    Untracked:  analysis/SingleCell_HierarchicalClustering_NoGeneFilter.Rmd
    Untracked:  analysis/SingleCell_VariancePartitionByCluster_Harmony.Batchindividual_ClusterRes0.1_minPCT0.2.Rmd
    Untracked:  analysis/VarPartPlots_res0.1_SCT.Rmd
    Untracked:  analysis/VarPart_SC_res0.1_SCT.Rmd
    Untracked:  analysis/child/
    Untracked:  analysis/k10topics_Explore.Rmd
    Untracked:  analysis/k6topics_Explore.Rmd
    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/ConvertToDGE.Rmd
    Untracked:  code/ConvertToDGE_PseudoBulk.Rmd
    Untracked:  code/ConvertToDGE_SingleCellRes_minPCT0.2.Rmd
    Untracked:  code/EB.getHumanMetadata.Rmd
    Untracked:  code/GEO_processed_data.Rmd
    Untracked:  code/PowerAnalysis_NoiseRatio.ipynb
    Untracked:  code/Untitled.ipynb
    Untracked:  code/Untitled1.ipynb
    Untracked:  code/compile_fits.Rmd
    Untracked:  code/fit_all_models.sh
    Untracked:  code/fit_poisson_nmf.R
    Untracked:  code/fit_poisson_nmf.sbatch
    Untracked:  code/functions_for_fit_comparison.Rmd
    Untracked:  code/get_genelist_byPCTthresh.Rmd
    Untracked:  code/prefit_poisson_nmf.R
    Untracked:  code/prefit_poisson_nmf.sbatch
    Untracked:  code/prepare_data_for_fastTopics.Rmd
    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/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/DownSampleVarPart.rds
    Untracked:  output/Frequency.MostCommonAnnotation.FiveNearestRefCells.csv
    Untracked:  output/GEOsubmissionProcessedFiles/
    Untracked:  output/GeneLists_by_minPCT/
    Untracked:  output/MostCommonAnnotation.FiveNearestRefCells.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/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:  slurm-12005914.out
    Untracked:  slurm-12005923.out

Unstaged changes:
    Deleted:    analysis/IntegrateAnalysis.afterFilter.HarmonyBatch.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.HarmonyBatchSampleIDindividual.Rmd
    Modified:   analysis/IntegrateAnalysis.afterFilter.HarmonyBatchindividual.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.NOHARMONYjustmerge.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.SCTregressBatchIndividual.Rmd
    Deleted:    analysis/IntegrateAnalysis.afterFilter.SCTregressBatchIndividualHarmonyBatchindividual.Rmd
    Modified:   analysis/Pseudobulk_HierarchicalClustering_Harmony.Batchindividual_ClusterRes0.1_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_HierarchicalClustering_Harmony.Batchindividual_ClusterRes0.5_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_HierarchicalClustering_Harmony.Batchindividual_ClusterRes0.8_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_HierarchicalClustering_Harmony.Batchindividual_ClusterRes1_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.1_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_Limma_Harmony.BatchIndividual_ClusterRes0.5_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_VariancePartition_Harmony.Batchindividual_ClusterRes0.1_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_VariancePartition_Harmony.Batchindividual_ClusterRes0.5_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_VariancePartition_Harmony.Batchindividual_ClusterRes0.8_minPCT0.2.Rmd
    Modified:   analysis/Pseudobulk_VariancePartition_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_HierarchicalClustering_Harmony.Batchindividual_ClusterRes0.8_minPCT0.2.Rmd) and HTML (docs/Pseudobulk_HierarchicalClustering_Harmony.Batchindividual_ClusterRes0.8_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
html 4e5b964 KLRhodes 2020-08-31 Build site.
Rmd 1bd899e KLRhodes 2020-08-31 wflow_publish("analysis/Pseudobulk_HierarchicalClustering_Harmony.Batchindividual_ClusterRes*")

library(ComplexHeatmap)
Loading required package: grid
========================================
ComplexHeatmap version 2.7.4
Bioconductor page: http://bioconductor.org/packages/ComplexHeatmap/
Github page: https://github.com/jokergoo/ComplexHeatmap
Documentation: http://jokergoo.github.io/ComplexHeatmap-reference

If you use it in published research, please cite:
Gu, Z. Complex heatmaps reveal patterns and correlations in multidimensional 
  genomic data. Bioinformatics 2016.

This message can be suppressed by:
  suppressPackageStartupMessages(library(ComplexHeatmap))
========================================
library(edgeR)
Loading required package: limma
f<- 'Harmony.Batchindividual'
pct<-0.2
res<- 'SCT_snn_res.0.8'
path<- here::here("output/DGELists/")
dge<- readRDS(paste0(path,"Pseudobulk_dge_",f, "_", res,"_minPCT",pct,".rds"))
pseudo.lcpm<- cpm(dge, log=TRUE)
ha<- HeatmapAnnotation(cluster= dge$samples$cluster, batch= dge$samples$batch, individual= dge$samples$ind)

Heatmap(pseudo.lcpm, bottom_annotation = ha, show_column_names = F, show_row_names = F, name = "lcpm", use_raster = TRUE)

Version Author Date
4e5b964 KLRhodes 2020-08-31

Same thing, removing ribosomal to see if it changes anything

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
pseudo.lcpm<- cpm(dge, log=TRUE)
ha<- HeatmapAnnotation(cluster= dge$samples$cluster, batch= dge$samples$batch, individual= dge$samples$ind)

Heatmap(pseudo.lcpm, bottom_annotation = ha, show_column_names = F, show_row_names = F, name = "lcpm", use_raster = TRUE)

Version Author Date
4e5b964 KLRhodes 2020-08-31
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] C

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

other attached packages:
[1] edgeR_3.28.1         limma_3.42.2         ComplexHeatmap_2.7.4
[4] workflowr_1.6.2     

loaded via a namespace (and not attached):
 [1] Rcpp_1.0.6          RColorBrewer_1.1-2  pillar_1.4.7       
 [4] compiler_3.6.1      later_1.1.0.1       git2r_0.26.1       
 [7] tools_3.6.1         digest_0.6.27       lattice_0.20-38    
[10] clue_0.3-58         evaluate_0.14       lifecycle_0.2.0    
[13] tibble_3.0.4        pkgconfig_2.0.3     png_0.1-7          
[16] rlang_0.4.10        magick_2.4.0        yaml_2.2.1         
[19] parallel_3.6.1      xfun_0.16           cluster_2.1.0      
[22] stringr_1.4.0       knitr_1.29          S4Vectors_0.24.4   
[25] fs_1.4.2            vctrs_0.3.6         GlobalOptions_0.1.2
[28] IRanges_2.20.2      locfit_1.5-9.4      stats4_3.6.1       
[31] rprojroot_2.0.2     here_0.1-11         glue_1.4.2         
[34] R6_2.5.0            GetoptLong_1.0.5    rmarkdown_2.3      
[37] magrittr_2.0.1      whisker_0.4         promises_1.1.1     
[40] ellipsis_0.3.1      htmltools_0.5.0     matrixStats_0.57.0 
[43] BiocGenerics_0.32.0 shape_1.4.5         colorspace_2.0-0   
[46] circlize_0.4.11     httpuv_1.5.4        stringi_1.5.3      
[49] crayon_1.3.4        rjson_0.2.20        Cairo_1.5-12.2     

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] C

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

other attached packages:
[1] edgeR_3.28.1         limma_3.42.2         ComplexHeatmap_2.7.4
[4] workflowr_1.6.2     

loaded via a namespace (and not attached):
 [1] Rcpp_1.0.6          RColorBrewer_1.1-2  pillar_1.4.7       
 [4] compiler_3.6.1      later_1.1.0.1       git2r_0.26.1       
 [7] tools_3.6.1         digest_0.6.27       lattice_0.20-38    
[10] clue_0.3-58         evaluate_0.14       lifecycle_0.2.0    
[13] tibble_3.0.4        pkgconfig_2.0.3     png_0.1-7          
[16] rlang_0.4.10        magick_2.4.0        yaml_2.2.1         
[19] parallel_3.6.1      xfun_0.16           cluster_2.1.0      
[22] stringr_1.4.0       knitr_1.29          S4Vectors_0.24.4   
[25] fs_1.4.2            vctrs_0.3.6         GlobalOptions_0.1.2
[28] IRanges_2.20.2      locfit_1.5-9.4      stats4_3.6.1       
[31] rprojroot_2.0.2     here_0.1-11         glue_1.4.2         
[34] R6_2.5.0            GetoptLong_1.0.5    rmarkdown_2.3      
[37] magrittr_2.0.1      whisker_0.4         promises_1.1.1     
[40] ellipsis_0.3.1      htmltools_0.5.0     matrixStats_0.57.0 
[43] BiocGenerics_0.32.0 shape_1.4.5         colorspace_2.0-0   
[46] circlize_0.4.11     httpuv_1.5.4        stringi_1.5.3      
[49] crayon_1.3.4        rjson_0.2.20        Cairo_1.5-12.2