This is an R Markdown Notebook. When you execute code within the notebook, the results appear beneath the code.
Try executing this chunk by clicking the Run button within the chunk or by placing your cursor inside it and pressing Ctrl+Shift+Enter.
Warning messages:
1: package ‘ensembldb’ was built under R version 4.3.3
2: package ‘GenomeInfoDb’ was built under R version 4.3.3
3: package ‘GenomicFeatures’ was built under R version 4.3.3
library(spatstat.utils)
Warning: package 'spatstat.utils' was built under R version 4.3.3
library(SeuratObject)
Warning: package 'SeuratObject' was built under R version 4.3.3
Loading required package: sp
Attaching package: 'sp'
The following object is masked from 'package:IRanges':
%over%
Attaching package: 'SeuratObject'
The following object is masked from 'package:GenomicRanges':
intersect
The following object is masked from 'package:GenomeInfoDb':
intersect
The following object is masked from 'package:IRanges':
intersect
The following object is masked from 'package:S4Vectors':
intersect
The following object is masked from 'package:BiocGenerics':
intersect
The following objects are masked from 'package:base':
intersect, t
library(harmony)
Warning: package 'harmony' was built under R version 4.3.3
Loading required package: Rcpp
library(Signac)
Warning: package 'Signac' was built under R version 4.3.3
library(Seurat)
Warning: package 'Seurat' was built under R version 4.3.3
library(GenomeInfoDb)
library(EnsDb.Mmusculus.v79)
library(dplyr)
Attaching package: 'dplyr'
The following objects are masked from 'package:ensembldb':
filter, select
The following object is masked from 'package:AnnotationDbi':
select
The following object is masked from 'package:Biobase':
combine
The following objects are masked from 'package:GenomicRanges':
intersect, setdiff, union
The following object is masked from 'package:GenomeInfoDb':
intersect
The following objects are masked from 'package:IRanges':
collapse, desc, intersect, setdiff, slice, union
The following objects are masked from 'package:S4Vectors':
first, intersect, rename, setdiff, setequal, union
The following objects are masked from 'package:BiocGenerics':
combine, intersect, setdiff, union
The following objects are masked from 'package:stats':
filter, lag
The following objects are masked from 'package:base':
intersect, setdiff, setequal, union
library(hdf5r)
Warning: package 'hdf5r' was built under R version 4.3.3
Attaching package: 'hdf5r'
The following object is masked from 'package:GenomicRanges':
values
The following object is masked from 'package:S4Vectors':
values
annotations <- GetGRangesFromEnsDb(ensdb = EnsDb.Mmusculus.v79)
| | 0 % ~calculating
|+++ | 5 % ~02m 02s
|+++++ | 9 % ~01m 36s
|+++++++ | 14% ~01m 13s
|++++++++++ | 18% ~01m 14s
|++++++++++++ | 23% ~01m 10s
|++++++++++++++ | 27% ~01m 03s
|++++++++++++++++ | 32% ~56s
|+++++++++++++++++++ | 36% ~53s
|+++++++++++++++++++++ | 41% ~50s
|+++++++++++++++++++++++ | 45% ~44s
|+++++++++++++++++++++++++ | 50% ~40s
|++++++++++++++++++++++++++++ | 55% ~37s
|++++++++++++++++++++++++++++++ | 59% ~34s
|++++++++++++++++++++++++++++++++ | 64% ~30s
|+++++++++++++++++++++++++++++++++++ | 68% ~26s
|+++++++++++++++++++++++++++++++++++++ | 73% ~22s
|+++++++++++++++++++++++++++++++++++++++ | 77% ~18s
|+++++++++++++++++++++++++++++++++++++++++ | 82% ~14s
|++++++++++++++++++++++++++++++++++++++++++++ | 86% ~11s
|++++++++++++++++++++++++++++++++++++++++++++++ | 91% ~07s
|++++++++++++++++++++++++++++++++++++++++++++++++ | 95% ~03s
|++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=01m 14s
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
Warning in .merge_two_Seqinfo_objects(x, y) :
The 2 combined objects have no sequence levels in common. (Use
suppressWarnings() to suppress this warning.)
count_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/filtered_peak_bc_matrix.h5"
meta_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/singlecell.csv"
fragment_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/fragments.tsv.gz"
import_atac <-function(count_path, meta_path, fragment_path)
{
counts <- Read10X_h5(filename = count_path)
print(fragment_path)
counts_Y <- counts[grep("Y", row.names(counts)),]
counts.keep <- counts[,apply(counts_Y, 2, function(x) all(x==0))]
meta <- read.csv(
file = meta_path,
header = TRUE,
row.names = 1)
chrom_assay <- CreateChromatinAssay(
counts = counts,
sep = c(":", "-"),
genome = 'GRCm38',
fragments = fragment_path,
min.cells = 10,
min.features = 200
)
data <- CreateSeuratObject(
counts = chrom_assay,
assay = "peaks",
meta.data = meta
)
Annotation(data) <- annotations
data <- NucleosomeSignal(object = data)
data <- TSSEnrichment(object = data, fast = FALSE)
data$blacklist_ratio <- data$blacklist_region_fragments / data$peak_region_fragments
data$pct_reads_in_peaks <- data$peak_region_fragments / data$passed_filters * 100
low_prf <- quantile(data[["peak_region_fragments"]]$peak_region_fragments, probs = 0.02)
hig_prf <- quantile(data[["peak_region_fragments"]]$peak_region_fragments, probs = 0.98)
low_prp <- quantile(data[["pct_reads_in_peaks"]]$pct_reads_in_peaks, probs = 0.02)
hig_ns <- quantile(data[["nucleosome_signal"]]$nucleosome_signal, probs = 0.98)
low_ts <- quantile(data[["TSS.enrichment"]]$TSS.enrichment, probs = 0.02)
data <- subset(
x = data,
subset = peak_region_fragments > low_prf &
peak_region_fragments < hig_prf &
pct_reads_in_peaks > low_prp &
nucleosome_signal < hig_ns &
TSS.enrichment > low_ts
)
data<-subset(data,subset=nCount_peaks > 1000 & nCount_peaks<10500)
data<-subset(data,subset=nFeature_peaks >500 & nFeature_peaks<5500)
VlnPlot(data,features=c("nCount_peaks","nFeature_peaks"),ncol=2)
#normalisation
data<- RunTFIDF(data)
data <- FindTopFeatures(data, min.cutoff = 'q0')
data <- RunSVD(data)
data <- RunUMAP(object = data, reduction = 'lsi', dims = 2:30)
data <- FindNeighbors(object = data, reduction = 'lsi', dims = 2:30)
data <- FindClusters(object = data, verbose = FALSE, algorithm = 3)
DimPlot(object = data, label = TRUE) + NoLegend()
return(data)
}
#genome 1
count_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/filtered_peak_bc_matrix.h5"
meta_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/singlecell.csv"
fragment_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/fragments.tsv.gz"
allele1=import_atac(count_path,meta_path,fragment_path)
[1] "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/fragments.tsv.gz"
Computing hash
Checking for 10905 cell barcodes
Found 10905 cell barcodes
Done Processing 1 million lines
Done Processing 2 million lines
Done Processing 3 million lines
Done Processing 4 million lines
Done Processing 5 million lines
Done Processing 6 million lines
Done Processing 7 million lines
Done Processing 8 million lines
Done Processing 9 million lines
Done Processing 10 million lines
Done Processing 11 million lines
Done Processing 12 million lines
Done Processing 13 million lines
Done Processing 14 million lines
Done Processing 15 million lines
Done Processing 16 million lines
Done Processing 17 million lines
Done Processing 18 million lines
Done Processing 19 million lines
Done Processing 20 million lines
Done Processing 21 million lines
Done Processing 22 million lines
Done Processing 23 million lines
Done Processing 24 million lines
Done Processing 25 million lines
Done Processing 26 million lines
Done Processing 27 million lines
Done Processing 28 million lines
Done Processing 29 million lines
Done Processing 30 million lines
Done Processing 31 million lines
Done Processing 32 million lines
Done Processing 33 million lines
Done Processing 34 million lines
Done Processing 35 million lines
Done Processing 36 million lines
Done Processing 37 million lines
Done Processing 38 million lines
Done Processing 39 million lines
Done Processing 40 million lines
Done Processing 41 million lines
Done Processing 42 million lines
Done Processing 43 million lines
Done Processing 44 million lines
Done Processing 45 million lines
Done Processing 46 million lines
Done Processing 47 million lines
Done Processing 48 million lines
Done Processing 49 million lines
Done Processing 50 million lines
Done Processing 51 million lines
Done Processing 52 million lines
Done Processing 53 million lines
Done Processing 54 million linesExtracting TSS positions
Finding + strand cut sites
Finding - strand cut sites
Computing mean insertion frequency in flanking regions
Normalizing TSS score
Performing TF-IDF normalization
Running SVD
Scaling cell embeddings
Warning: The default method for RunUMAP has changed from calling Python UMAP via reticulate to the R-native UWOT using the cosine metric
To use Python UMAP via reticulate, set umap.method to 'umap-learn' and metric to 'correlation'
This message will be shown once per session
20:25:32 UMAP embedding parameters a = 0.9922 b = 1.112
20:25:32 Read 10060 rows and found 29 numeric columns
20:25:32 Using Annoy for neighbor search, n_neighbors = 30
20:25:32 Building Annoy index with metric = cosine, n_trees = 50
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
20:25:35 Writing NN index file to temp file C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\file9918335f3094
20:25:35 Searching Annoy index using 1 thread, search_k = 3000
20:25:43 Annoy recall = 100%
20:25:51 Commencing smooth kNN distance calibration using 1 thread with target n_neighbors = 30
20:25:56 Initializing from normalized Laplacian + noise (using RSpectra)
20:25:56 Commencing optimization for 200 epochs, with 366034 positive edges
Using method 'umap'
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
20:26:13 Optimization finished
Computing nearest neighbor graph
Computing SNN
#genome 2
count_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome2/filtered_peak_bc_matrix.h5"
meta_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome2/singlecell.csv"
fragment_path="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome2/fragments.tsv.gz"
allele2=import_atac(count_path,meta_path,fragment_path)
[1] "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome2/fragments.tsv.gz"
Computing hash
Checking for 10950 cell barcodes
Found 10950 cell barcodes
Done Processing 1 million lines
Done Processing 2 million lines
Done Processing 3 million lines
Done Processing 4 million lines
Done Processing 5 million lines
Done Processing 6 million lines
Done Processing 7 million lines
Done Processing 8 million lines
Done Processing 9 million lines
Done Processing 10 million lines
Done Processing 11 million lines
Done Processing 12 million lines
Done Processing 13 million lines
Done Processing 14 million lines
Done Processing 15 million lines
Done Processing 16 million lines
Done Processing 17 million lines
Done Processing 18 million lines
Done Processing 19 million lines
Done Processing 20 million lines
Done Processing 21 million lines
Done Processing 22 million lines
Done Processing 23 million lines
Done Processing 24 million lines
Done Processing 25 million lines
Done Processing 26 million lines
Done Processing 27 million lines
Done Processing 28 million lines
Done Processing 29 million lines
Done Processing 30 million lines
Done Processing 31 million lines
Done Processing 32 million lines
Done Processing 33 million lines
Done Processing 34 million lines
Done Processing 35 million lines
Done Processing 36 million lines
Done Processing 37 million lines
Done Processing 38 million lines
Done Processing 39 million lines
Done Processing 40 million lines
Done Processing 41 million lines
Done Processing 42 million lines
Done Processing 43 million lines
Done Processing 44 million lines
Done Processing 45 million lines
Done Processing 46 million lines
Done Processing 47 million lines
Done Processing 48 million lines
Done Processing 49 million lines
Done Processing 50 million lines
Done Processing 51 million lines
Done Processing 52 million lines
Done Processing 53 million lines
Done Processing 54 million linesExtracting TSS positions
Finding + strand cut sites
[W::hts_idx_load3] The index file is older than the data file: C:\Users\helper\Documents\yofith\fichiersprojetsbioinfo\genome2\fragments.tsv.gz.tbi
Finding - strand cut sites
[W::hts_idx_load3] The index file is older than the data file: C:\Users\helper\Documents\yofith\fichiersprojetsbioinfo\genome2\fragments.tsv.gz.tbi
Computing mean insertion frequency in flanking regions
Normalizing TSS score
Performing TF-IDF normalization
Running SVD
Scaling cell embeddings
20:36:53 UMAP embedding parameters a = 0.9922 b = 1.112
20:36:54 Read 10018 rows and found 29 numeric columns
20:36:54 Using Annoy for neighbor search, n_neighbors = 30
20:36:54 Building Annoy index with metric = cosine, n_trees = 50
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
20:36:56 Writing NN index file to temp file C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\file99181beb2076
20:36:56 Searching Annoy index using 1 thread, search_k = 3000
20:37:03 Annoy recall = 100%
20:37:52 Commencing smooth kNN distance calibration using 1 thread with target n_neighbors = 30
20:38:02 Initializing from normalized Laplacian + noise (using RSpectra)
20:38:03 Commencing optimization for 200 epochs, with 358414 positive edges
Using method 'umap'
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
20:38:20 Optimization finished
Computing nearest neighbor graph
Computing SNN
save.image("C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/scATAC.RData")
cells.to.keep <- intersect(row.names(allele2@meta.data),
row.names(allele1@meta.data))
cells.to.keep <- intersect(cells.to.keep, row.names(allele2@meta.data))
length(cells.to.keep)
[1] 9321
allele1 <- subset(allele1,
cells = cells.to.keep)
allele2 <- subset(allele2,
cells = cells.to.keep)
allele1$dataset <- "allele1"
allele2$dataset <- "allele2"
allele1_cells <- rownames(allele1@meta.data)
allele2_cells <- rownames(allele2@meta.data)
cell_names_identical <- identical( sort(allele1_cells),sort(allele2_cells))
unintegrated <- merge(x=allele1, y=allele2, add.cell.ids=c("allele1","allele2"))
|
| | 0%
|
|= | 0%
|
|= | 1%
|
|== | 1%
|
|== | 2%
|
|=== | 2%
|
|=== | 3%
|
|==== | 3%
|
|==== | 4%
|
|===== | 4%
|
|===== | 5%
|
|====== | 5%
|
|======= | 5%
|
|======= | 6%
|
|======== | 6%
|
|======== | 7%
|
|========= | 7%
|
|========= | 8%
|
|========== | 8%
|
|========== | 9%
|
|=========== | 9%
|
|=========== | 10%
|
|============ | 10%
|
|============= | 10%
|
|============= | 11%
|
|============== | 11%
|
|============== | 12%
|
|=============== | 12%
|
|=============== | 13%
|
|================ | 13%
|
|================ | 14%
|
|================= | 14%
|
|================= | 15%
|
|================== | 15%
|
|=================== | 15%
|
|=================== | 16%
|
|==================== | 16%
|
|==================== | 17%
|
|===================== | 17%
|
|===================== | 18%
|
|====================== | 18%
|
|====================== | 19%
|
|======================= | 19%
|
|======================= | 20%
|
|======================== | 20%
|
|========================= | 20%
|
|========================= | 21%
|
|========================== | 21%
|
|========================== | 22%
|
|=========================== | 22%
|
|=========================== | 23%
|
|============================ | 23%
|
|============================ | 24%
|
|============================= | 24%
|
|============================= | 25%
|
|============================== | 25%
|
|=============================== | 25%
|
|=============================== | 26%
|
|================================ | 26%
|
|================================ | 27%
|
|================================= | 27%
|
|================================= | 28%
|
|================================== | 28%
|
|================================== | 29%
|
|=================================== | 29%
|
|=================================== | 30%
|
|==================================== | 30%
|
|===================================== | 30%
|
|===================================== | 31%
|
|====================================== | 31%
|
|====================================== | 32%
|
|======================================= | 32%
|
|======================================= | 33%
|
|======================================== | 33%
|
|======================================== | 34%
|
|========================================= | 34%
|
|========================================= | 35%
|
|========================================== | 35%
|
|=========================================== | 35%
|
|=========================================== | 36%
|
|============================================ | 36%
|
|============================================ | 37%
|
|============================================= | 37%
|
|============================================= | 38%
|
|============================================== | 38%
|
|============================================== | 39%
|
|=============================================== | 39%
|
|=============================================== | 40%
|
|================================================ | 40%
|
|================================================= | 40%
|
|================================================= | 41%
|
|================================================== | 41%
|
|================================================== | 42%
|
|=================================================== | 42%
|
|=================================================== | 43%
|
|==================================================== | 43%
|
|==================================================== | 44%
|
|===================================================== | 44%
|
|===================================================== | 45%
|
|====================================================== | 45%
|
|======================================================= | 45%
|
|======================================================= | 46%
|
|======================================================== | 46%
|
|======================================================== | 47%
|
|========================================================= | 47%
|
|========================================================= | 48%
|
|========================================================== | 48%
|
|========================================================== | 49%
|
|=========================================================== | 49%
|
|=========================================================== | 50%
|
|============================================================ | 50%
|
|============================================================= | 50%
|
|============================================================= | 51%
|
|============================================================== | 51%
|
|============================================================== | 52%
|
|=============================================================== | 52%
|
|=============================================================== | 53%
|
|================================================================ | 53%
|
|================================================================ | 54%
|
|================================================================= | 54%
|
|================================================================= | 55%
|
|================================================================== | 55%
|
|=================================================================== | 55%
|
|=================================================================== | 56%
|
|==================================================================== | 56%
|
|==================================================================== | 57%
|
|===================================================================== | 57%
|
|===================================================================== | 58%
|
|====================================================================== | 58%
|
|====================================================================== | 59%
|
|======================================================================= | 59%
|
|======================================================================= | 60%
|
|======================================================================== | 60%
|
|========================================================================= | 60%
|
|========================================================================= | 61%
|
|========================================================================== | 61%
|
|========================================================================== | 62%
|
|=========================================================================== | 62%
|
|=========================================================================== | 63%
|
|============================================================================ | 63%
|
|============================================================================ | 64%
|
|============================================================================= | 64%
|
|============================================================================= | 65%
|
|============================================================================== | 65%
|
|=============================================================================== | 65%
|
|=============================================================================== | 66%
|
|================================================================================ | 66%
|
|================================================================================ | 67%
|
|================================================================================= | 67%
|
|================================================================================= | 68%
|
|================================================================================== | 68%
|
|================================================================================== | 69%
|
|=================================================================================== | 69%
|
|=================================================================================== | 70%
|
|==================================================================================== | 70%
|
|===================================================================================== | 70%
|
|===================================================================================== | 71%
|
|====================================================================================== | 71%
|
|====================================================================================== | 72%
|
|======================================================================================= | 72%
|
|======================================================================================= | 73%
|
|======================================================================================== | 73%
|
|======================================================================================== | 74%
|
|========================================================================================= | 74%
|
|========================================================================================= | 75%
|
|========================================================================================== | 75%
|
|=========================================================================================== | 75%
|
|=========================================================================================== | 76%
|
|============================================================================================ | 76%
|
|============================================================================================ | 77%
|
|============================================================================================= | 77%
|
|============================================================================================= | 78%
|
|============================================================================================== | 78%
|
|============================================================================================== | 79%
|
|=============================================================================================== | 79%
|
|=============================================================================================== | 80%
|
|================================================================================================ | 80%
|
|================================================================================================= | 80%
|
|================================================================================================= | 81%
|
|================================================================================================== | 81%
|
|================================================================================================== | 82%
|
|=================================================================================================== | 82%
|
|=================================================================================================== | 83%
|
|==================================================================================================== | 83%
|
|==================================================================================================== | 84%
|
|===================================================================================================== | 84%
|
|===================================================================================================== | 85%
|
|====================================================================================================== | 85%
|
|======================================================================================================= | 85%
|
|======================================================================================================= | 86%
|
|======================================================================================================== | 86%
|
|======================================================================================================== | 87%
|
|========================================================================================================= | 87%
|
|========================================================================================================= | 88%
|
|========================================================================================================== | 88%
|
|========================================================================================================== | 89%
|
|=========================================================================================================== | 89%
|
|=========================================================================================================== | 90%
|
|============================================================================================================ | 90%
|
|============================================================================================================= | 90%
|
|============================================================================================================= | 91%
|
|============================================================================================================== | 91%
|
|============================================================================================================== | 92%
|
|=============================================================================================================== | 92%
|
|=============================================================================================================== | 93%
|
|================================================================================================================ | 93%
|
|================================================================================================================ | 94%
|
|================================================================================================================= | 94%
|
|================================================================================================================= | 95%
|
|================================================================================================================== | 95%
|
|=================================================================================================================== | 95%
|
|=================================================================================================================== | 96%
|
|==================================================================================================================== | 96%
|
|==================================================================================================================== | 97%
|
|===================================================================================================================== | 97%
|
|===================================================================================================================== | 98%
|
|====================================================================================================================== | 98%
|
|====================================================================================================================== | 99%
|
|======================================================================================================================= | 99%
|
|======================================================================================================================= | 100%
|
|========================================================================================================================| 100%
Binding matrix rows
|
| | 0%
|
|= | 0%
|
|= | 1%
|
|== | 1%
|
|== | 2%
|
|=== | 2%
|
|=== | 3%
|
|==== | 3%
|
|==== | 4%
|
|===== | 4%
|
|===== | 5%
|
|====== | 5%
|
|======= | 5%
|
|======= | 6%
|
|======== | 6%
|
|======== | 7%
|
|========= | 7%
|
|========= | 8%
|
|========== | 8%
|
|========== | 9%
|
|=========== | 9%
|
|=========== | 10%
|
|============ | 10%
|
|============= | 10%
|
|============= | 11%
|
|============== | 11%
|
|============== | 12%
|
|=============== | 12%
|
|=============== | 13%
|
|================ | 13%
|
|================ | 14%
|
|================= | 14%
|
|================= | 15%
|
|================== | 15%
|
|=================== | 15%
|
|=================== | 16%
|
|==================== | 16%
|
|==================== | 17%
|
|===================== | 17%
|
|===================== | 18%
|
|====================== | 18%
|
|====================== | 19%
|
|======================= | 19%
|
|======================= | 20%
|
|======================== | 20%
|
|========================= | 20%
|
|========================= | 21%
|
|========================== | 21%
|
|========================== | 22%
|
|=========================== | 22%
|
|=========================== | 23%
|
|============================ | 23%
|
|============================ | 24%
|
|============================= | 24%
|
|============================= | 25%
|
|============================== | 25%
|
|=============================== | 25%
|
|=============================== | 26%
|
|================================ | 26%
|
|================================ | 27%
|
|================================= | 27%
|
|================================= | 28%
|
|================================== | 28%
|
|================================== | 29%
|
|=================================== | 29%
|
|=================================== | 30%
|
|==================================== | 30%
|
|===================================== | 30%
|
|===================================== | 31%
|
|====================================== | 31%
|
|====================================== | 32%
|
|======================================= | 32%
|
|======================================= | 33%
|
|======================================== | 33%
|
|======================================== | 34%
|
|========================================= | 34%
|
|========================================= | 35%
|
|========================================== | 35%
|
|=========================================== | 35%
|
|=========================================== | 36%
|
|============================================ | 36%
|
|============================================ | 37%
|
|============================================= | 37%
|
|============================================= | 38%
|
|============================================== | 38%
|
|============================================== | 39%
|
|=============================================== | 39%
|
|=============================================== | 40%
|
|================================================ | 40%
|
|================================================= | 40%
|
|================================================= | 41%
|
|================================================== | 41%
|
|================================================== | 42%
|
|=================================================== | 42%
|
|=================================================== | 43%
|
|==================================================== | 43%
|
|==================================================== | 44%
|
|===================================================== | 44%
|
|===================================================== | 45%
|
|====================================================== | 45%
|
|======================================================= | 45%
|
|======================================================= | 46%
|
|======================================================== | 46%
|
|======================================================== | 47%
|
|========================================================= | 47%
|
|========================================================= | 48%
|
|========================================================== | 48%
|
|========================================================== | 49%
|
|=========================================================== | 49%
|
|=========================================================== | 50%
|
|============================================================ | 50%
|
|============================================================= | 50%
|
|============================================================= | 51%
|
|============================================================== | 51%
|
|============================================================== | 52%
|
|=============================================================== | 52%
|
|=============================================================== | 53%
|
|================================================================ | 53%
|
|================================================================ | 54%
|
|================================================================= | 54%
|
|================================================================= | 55%
|
|================================================================== | 55%
|
|=================================================================== | 55%
|
|=================================================================== | 56%
|
|==================================================================== | 56%
|
|==================================================================== | 57%
|
|===================================================================== | 57%
|
|===================================================================== | 58%
|
|====================================================================== | 58%
|
|====================================================================== | 59%
|
|======================================================================= | 59%
|
|======================================================================= | 60%
|
|======================================================================== | 60%
|
|========================================================================= | 60%
|
|========================================================================= | 61%
|
|========================================================================== | 61%
|
|========================================================================== | 62%
|
|=========================================================================== | 62%
|
|=========================================================================== | 63%
|
|============================================================================ | 63%
|
|============================================================================ | 64%
|
|============================================================================= | 64%
|
|============================================================================= | 65%
|
|============================================================================== | 65%
|
|=============================================================================== | 65%
|
|=============================================================================== | 66%
|
|================================================================================ | 66%
|
|================================================================================ | 67%
|
|================================================================================= | 67%
|
|================================================================================= | 68%
|
|================================================================================== | 68%
|
|================================================================================== | 69%
|
|=================================================================================== | 69%
|
|=================================================================================== | 70%
|
|==================================================================================== | 70%
|
|===================================================================================== | 70%
|
|===================================================================================== | 71%
|
|====================================================================================== | 71%
|
|====================================================================================== | 72%
|
|======================================================================================= | 72%
|
|======================================================================================= | 73%
|
|======================================================================================== | 73%
|
|======================================================================================== | 74%
|
|========================================================================================= | 74%
|
|========================================================================================= | 75%
|
|========================================================================================== | 75%
|
|=========================================================================================== | 75%
|
|=========================================================================================== | 76%
|
|============================================================================================ | 76%
|
|============================================================================================ | 77%
|
|============================================================================================= | 77%
|
|============================================================================================= | 78%
|
|============================================================================================== | 78%
|
|============================================================================================== | 79%
|
|=============================================================================================== | 79%
|
|=============================================================================================== | 80%
|
|================================================================================================ | 80%
|
|================================================================================================= | 80%
|
|================================================================================================= | 81%
|
|================================================================================================== | 81%
|
|================================================================================================== | 82%
|
|=================================================================================================== | 82%
|
|=================================================================================================== | 83%
|
|==================================================================================================== | 83%
|
|==================================================================================================== | 84%
|
|===================================================================================================== | 84%
|
|===================================================================================================== | 85%
|
|====================================================================================================== | 85%
|
|======================================================================================================= | 85%
|
|======================================================================================================= | 86%
|
|======================================================================================================== | 86%
|
|======================================================================================================== | 87%
|
|========================================================================================================= | 87%
|
|========================================================================================================= | 88%
|
|========================================================================================================== | 88%
|
|========================================================================================================== | 89%
|
|=========================================================================================================== | 89%
|
|=========================================================================================================== | 90%
|
|============================================================================================================ | 90%
|
|============================================================================================================= | 90%
|
|============================================================================================================= | 91%
|
|============================================================================================================== | 91%
|
|============================================================================================================== | 92%
|
|=============================================================================================================== | 92%
|
|=============================================================================================================== | 93%
|
|================================================================================================================ | 93%
|
|================================================================================================================ | 94%
|
|================================================================================================================= | 94%
|
|================================================================================================================= | 95%
|
|================================================================================================================== | 95%
|
|=================================================================================================================== | 95%
|
|=================================================================================================================== | 96%
|
|==================================================================================================================== | 96%
|
|==================================================================================================================== | 97%
|
|===================================================================================================================== | 97%
|
|===================================================================================================================== | 98%
|
|====================================================================================================================== | 98%
|
|====================================================================================================================== | 99%
|
|======================================================================================================================= | 99%
|
|======================================================================================================================= | 100%
|
|========================================================================================================================| 100%
Binding matrix rows
|
| | 0%
|
|= | 0%
|
|= | 1%
|
|== | 1%
|
|== | 2%
|
|=== | 2%
|
|=== | 3%
|
|==== | 3%
|
|==== | 4%
|
|===== | 4%
|
|===== | 5%
|
|====== | 5%
|
|======= | 5%
|
|======= | 6%
|
|======== | 6%
|
|======== | 7%
|
|========= | 7%
|
|========= | 8%
|
|========== | 8%
|
|========== | 9%
|
|=========== | 9%
|
|=========== | 10%
|
|============ | 10%
|
|============= | 10%
|
|============= | 11%
|
|============== | 11%
|
|============== | 12%
|
|=============== | 12%
|
|=============== | 13%
|
|================ | 13%
|
|================ | 14%
|
|================= | 14%
|
|================= | 15%
|
|================== | 15%
|
|=================== | 15%
|
|=================== | 16%
|
|==================== | 16%
|
|==================== | 17%
|
|===================== | 17%
|
|===================== | 18%
|
|====================== | 18%
|
|====================== | 19%
|
|======================= | 19%
|
|======================= | 20%
|
|======================== | 20%
|
|========================= | 20%
|
|========================= | 21%
|
|========================== | 21%
|
|========================== | 22%
|
|=========================== | 22%
|
|=========================== | 23%
|
|============================ | 23%
|
|============================ | 24%
|
|============================= | 24%
|
|============================= | 25%
|
|============================== | 25%
|
|=============================== | 25%
|
|=============================== | 26%
|
|================================ | 26%
|
|================================ | 27%
|
|================================= | 27%
|
|================================= | 28%
|
|================================== | 28%
|
|================================== | 29%
|
|=================================== | 29%
|
|=================================== | 30%
|
|==================================== | 30%
|
|===================================== | 30%
|
|===================================== | 31%
|
|====================================== | 31%
|
|====================================== | 32%
|
|======================================= | 32%
|
|======================================= | 33%
|
|======================================== | 33%
|
|======================================== | 34%
|
|========================================= | 34%
|
|========================================= | 35%
|
|========================================== | 35%
|
|=========================================== | 35%
|
|=========================================== | 36%
|
|============================================ | 36%
|
|============================================ | 37%
|
|============================================= | 37%
|
|============================================= | 38%
|
|============================================== | 38%
|
|============================================== | 39%
|
|=============================================== | 39%
|
|=============================================== | 40%
|
|================================================ | 40%
|
|================================================= | 40%
|
|================================================= | 41%
|
|================================================== | 41%
|
|================================================== | 42%
|
|=================================================== | 42%
|
|=================================================== | 43%
|
|==================================================== | 43%
|
|==================================================== | 44%
|
|===================================================== | 44%
|
|===================================================== | 45%
|
|====================================================== | 45%
|
|======================================================= | 45%
|
|======================================================= | 46%
|
|======================================================== | 46%
|
|======================================================== | 47%
|
|========================================================= | 47%
|
|========================================================= | 48%
|
|========================================================== | 48%
|
|========================================================== | 49%
|
|=========================================================== | 49%
|
|=========================================================== | 50%
|
|============================================================ | 50%
|
|============================================================= | 50%
|
|============================================================= | 51%
|
|============================================================== | 51%
|
|============================================================== | 52%
|
|=============================================================== | 52%
|
|=============================================================== | 53%
|
|================================================================ | 53%
|
|================================================================ | 54%
|
|================================================================= | 54%
|
|================================================================= | 55%
|
|================================================================== | 55%
|
|=================================================================== | 55%
|
|=================================================================== | 56%
|
|==================================================================== | 56%
|
|==================================================================== | 57%
|
|===================================================================== | 57%
|
|===================================================================== | 58%
|
|====================================================================== | 58%
|
|====================================================================== | 59%
|
|======================================================================= | 59%
|
|======================================================================= | 60%
|
|======================================================================== | 60%
|
|========================================================================= | 60%
|
|========================================================================= | 61%
|
|========================================================================== | 61%
|
|========================================================================== | 62%
|
|=========================================================================== | 62%
|
|=========================================================================== | 63%
|
|============================================================================ | 63%
|
|============================================================================ | 64%
|
|============================================================================= | 64%
|
|============================================================================= | 65%
|
|============================================================================== | 65%
|
|=============================================================================== | 65%
|
|=============================================================================== | 66%
|
|================================================================================ | 66%
|
|================================================================================ | 67%
|
|================================================================================= | 67%
|
|================================================================================= | 68%
|
|================================================================================== | 68%
|
|================================================================================== | 69%
|
|=================================================================================== | 69%
|
|=================================================================================== | 70%
|
|==================================================================================== | 70%
|
|===================================================================================== | 70%
|
|===================================================================================== | 71%
|
|====================================================================================== | 71%
|
|====================================================================================== | 72%
|
|======================================================================================= | 72%
|
|======================================================================================= | 73%
|
|======================================================================================== | 73%
|
|======================================================================================== | 74%
|
|========================================================================================= | 74%
|
|========================================================================================= | 75%
|
|========================================================================================== | 75%
|
|=========================================================================================== | 75%
|
|=========================================================================================== | 76%
|
|============================================================================================ | 76%
|
|============================================================================================ | 77%
|
|============================================================================================= | 77%
|
|============================================================================================= | 78%
|
|============================================================================================== | 78%
|
|============================================================================================== | 79%
|
|=============================================================================================== | 79%
|
|=============================================================================================== | 80%
|
|================================================================================================ | 80%
|
|================================================================================================= | 80%
|
|================================================================================================= | 81%
|
|================================================================================================== | 81%
|
|================================================================================================== | 82%
|
|=================================================================================================== | 82%
|
|=================================================================================================== | 83%
|
|==================================================================================================== | 83%
|
|==================================================================================================== | 84%
|
|===================================================================================================== | 84%
|
|===================================================================================================== | 85%
|
|====================================================================================================== | 85%
|
|======================================================================================================= | 85%
|
|======================================================================================================= | 86%
|
|======================================================================================================== | 86%
|
|======================================================================================================== | 87%
|
|========================================================================================================= | 87%
|
|========================================================================================================= | 88%
|
|========================================================================================================== | 88%
|
|========================================================================================================== | 89%
|
|=========================================================================================================== | 89%
|
|=========================================================================================================== | 90%
|
|============================================================================================================ | 90%
|
|============================================================================================================= | 90%
|
|============================================================================================================= | 91%
|
|============================================================================================================== | 91%
|
|============================================================================================================== | 92%
|
|=============================================================================================================== | 92%
|
|=============================================================================================================== | 93%
|
|================================================================================================================ | 93%
|
|================================================================================================================ | 94%
|
|================================================================================================================= | 94%
|
|================================================================================================================= | 95%
|
|================================================================================================================== | 95%
|
|=================================================================================================================== | 95%
|
|=================================================================================================================== | 96%
|
|==================================================================================================================== | 96%
|
|==================================================================================================================== | 97%
|
|===================================================================================================================== | 97%
|
|===================================================================================================================== | 98%
|
|====================================================================================================================== | 98%
|
|====================================================================================================================== | 99%
|
|======================================================================================================================= | 99%
|
|======================================================================================================================= | 100%
|
|========================================================================================================================| 100%
Binding matrix rows
|
| | 0%
|
|= | 0%
|
|= | 1%
|
|== | 1%
|
|== | 2%
|
|=== | 2%
|
|=== | 3%
|
|==== | 3%
|
|==== | 4%
|
|===== | 4%
|
|===== | 5%
|
|====== | 5%
|
|======= | 5%
|
|======= | 6%
|
|======== | 6%
|
|======== | 7%
|
|========= | 7%
|
|========= | 8%
|
|========== | 8%
|
|========== | 9%
|
|=========== | 9%
|
|=========== | 10%
|
|============ | 10%
|
|============= | 10%
|
|============= | 11%
|
|============== | 11%
|
|============== | 12%
|
|=============== | 12%
|
|=============== | 13%
|
|================ | 13%
|
|================ | 14%
|
|================= | 14%
|
|================= | 15%
|
|================== | 15%
|
|=================== | 15%
|
|=================== | 16%
|
|==================== | 16%
|
|==================== | 17%
|
|===================== | 17%
|
|===================== | 18%
|
|====================== | 18%
|
|====================== | 19%
|
|======================= | 19%
|
|======================= | 20%
|
|======================== | 20%
|
|========================= | 20%
|
|========================= | 21%
|
|========================== | 21%
|
|========================== | 22%
|
|=========================== | 22%
|
|=========================== | 23%
|
|============================ | 23%
|
|============================ | 24%
|
|============================= | 24%
|
|============================= | 25%
|
|============================== | 25%
|
|=============================== | 25%
|
|=============================== | 26%
|
|================================ | 26%
|
|================================ | 27%
|
|================================= | 27%
|
|================================= | 28%
|
|================================== | 28%
|
|================================== | 29%
|
|=================================== | 29%
|
|=================================== | 30%
|
|==================================== | 30%
|
|===================================== | 30%
|
|===================================== | 31%
|
|====================================== | 31%
|
|====================================== | 32%
|
|======================================= | 32%
|
|======================================= | 33%
|
|======================================== | 33%
|
|======================================== | 34%
|
|========================================= | 34%
|
|========================================= | 35%
|
|========================================== | 35%
|
|=========================================== | 35%
|
|=========================================== | 36%
|
|============================================ | 36%
|
|============================================ | 37%
|
|============================================= | 37%
|
|============================================= | 38%
|
|============================================== | 38%
|
|============================================== | 39%
|
|=============================================== | 39%
|
|=============================================== | 40%
|
|================================================ | 40%
|
|================================================= | 40%
|
|================================================= | 41%
|
|================================================== | 41%
|
|================================================== | 42%
|
|=================================================== | 42%
|
|=================================================== | 43%
|
|==================================================== | 43%
|
|==================================================== | 44%
|
|===================================================== | 44%
|
|===================================================== | 45%
|
|====================================================== | 45%
|
|======================================================= | 45%
|
|======================================================= | 46%
|
|======================================================== | 46%
|
|======================================================== | 47%
|
|========================================================= | 47%
|
|========================================================= | 48%
|
|========================================================== | 48%
|
|========================================================== | 49%
|
|=========================================================== | 49%
|
|=========================================================== | 50%
|
|============================================================ | 50%
|
|============================================================= | 50%
|
|============================================================= | 51%
|
|============================================================== | 51%
|
|============================================================== | 52%
|
|=============================================================== | 52%
|
|=============================================================== | 53%
|
|================================================================ | 53%
|
|================================================================ | 54%
|
|================================================================= | 54%
|
|================================================================= | 55%
|
|================================================================== | 55%
|
|=================================================================== | 55%
|
|=================================================================== | 56%
|
|==================================================================== | 56%
|
|==================================================================== | 57%
|
|===================================================================== | 57%
|
|===================================================================== | 58%
|
|====================================================================== | 58%
|
|====================================================================== | 59%
|
|======================================================================= | 59%
|
|======================================================================= | 60%
|
|======================================================================== | 60%
|
|========================================================================= | 60%
|
|========================================================================= | 61%
|
|========================================================================== | 61%
|
|========================================================================== | 62%
|
|=========================================================================== | 62%
|
|=========================================================================== | 63%
|
|============================================================================ | 63%
|
|============================================================================ | 64%
|
|============================================================================= | 64%
|
|============================================================================= | 65%
|
|============================================================================== | 65%
|
|=============================================================================== | 65%
|
|=============================================================================== | 66%
|
|================================================================================ | 66%
|
|================================================================================ | 67%
|
|================================================================================= | 67%
|
|================================================================================= | 68%
|
|================================================================================== | 68%
|
|================================================================================== | 69%
|
|=================================================================================== | 69%
|
|=================================================================================== | 70%
|
|==================================================================================== | 70%
|
|===================================================================================== | 70%
|
|===================================================================================== | 71%
|
|====================================================================================== | 71%
|
|====================================================================================== | 72%
|
|======================================================================================= | 72%
|
|======================================================================================= | 73%
|
|======================================================================================== | 73%
|
|======================================================================================== | 74%
|
|========================================================================================= | 74%
|
|========================================================================================= | 75%
|
|========================================================================================== | 75%
|
|=========================================================================================== | 75%
|
|=========================================================================================== | 76%
|
|============================================================================================ | 76%
|
|============================================================================================ | 77%
|
|============================================================================================= | 77%
|
|============================================================================================= | 78%
|
|============================================================================================== | 78%
|
|============================================================================================== | 79%
|
|=============================================================================================== | 79%
|
|=============================================================================================== | 80%
|
|================================================================================================ | 80%
|
|================================================================================================= | 80%
|
|================================================================================================= | 81%
|
|================================================================================================== | 81%
|
|================================================================================================== | 82%
|
|=================================================================================================== | 82%
|
|=================================================================================================== | 83%
|
|==================================================================================================== | 83%
|
|==================================================================================================== | 84%
|
|===================================================================================================== | 84%
|
|===================================================================================================== | 85%
|
|====================================================================================================== | 85%
|
|======================================================================================================= | 85%
|
|======================================================================================================= | 86%
|
|======================================================================================================== | 86%
|
|======================================================================================================== | 87%
|
|========================================================================================================= | 87%
|
|========================================================================================================= | 88%
|
|========================================================================================================== | 88%
|
|========================================================================================================== | 89%
|
|=========================================================================================================== | 89%
|
|=========================================================================================================== | 90%
|
|============================================================================================================ | 90%
|
|============================================================================================================= | 90%
|
|============================================================================================================= | 91%
|
|============================================================================================================== | 91%
|
|============================================================================================================== | 92%
|
|=============================================================================================================== | 92%
|
|=============================================================================================================== | 93%
|
|================================================================================================================ | 93%
|
|================================================================================================================ | 94%
|
|================================================================================================================= | 94%
|
|================================================================================================================= | 95%
|
|================================================================================================================== | 95%
|
|=================================================================================================================== | 95%
|
|=================================================================================================================== | 96%
|
|==================================================================================================================== | 96%
|
|==================================================================================================================== | 97%
|
|===================================================================================================================== | 97%
|
|===================================================================================================================== | 98%
|
|====================================================================================================================== | 98%
|
|====================================================================================================================== | 99%
|
|======================================================================================================================= | 99%
|
|======================================================================================================================= | 100%
|
|========================================================================================================================| 100%
Binding matrix rows
unintegrated <- RunTFIDF(unintegrated)
Performing TF-IDF normalization
unintegrated <- FindTopFeatures(unintegrated, min.cutoff = 20)
unintegrated <- RunSVD(unintegrated)
Running SVD
Scaling cell embeddings
unintegrated <- RunUMAP(unintegrated, reduction = "lsi", dims = 2:50)
21:33:11 UMAP embedding parameters a = 0.9922 b = 1.112
21:33:11 Read 18642 rows and found 49 numeric columns
21:33:11 Using Annoy for neighbor search, n_neighbors = 30
21:33:11 Building Annoy index with metric = cosine, n_trees = 50
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:33:19 Writing NN index file to temp file C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\file991830d310b2
21:33:19 Searching Annoy index using 1 thread, search_k = 3000
21:33:39 Annoy recall = 100%
21:34:11 Commencing smooth kNN distance calibration using 1 thread with target n_neighbors = 30
21:34:18 Initializing from normalized Laplacian + noise (using RSpectra)
21:34:19 Commencing optimization for 200 epochs, with 702158 positive edges
Using method 'umap'
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:35:06 Optimization finished
p1 <- DimPlot(unintegrated, group.by = 'dataset',pt.size=0.1)
hm.integrated <- RunHarmony(
object = unintegrated,
group.by.vars = 'dataset',
reduction.use = "lsi",
dims.use = 1:30,
reduction.save = "harmony",
project.dim = FALSE,
)
Transposing data matrix
Initializing state using k-means centroids initialization
Harmony 1/10
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
Harmony 2/10
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
Harmony 3/10
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
Harmony converged after 3 iterations
hm.integrated<- RunUMAP(hm.integrated, dims=1:30,reduction='harmony')
21:35:51 UMAP embedding parameters a = 0.9922 b = 1.112
21:35:51 Read 18642 rows and found 30 numeric columns
21:35:51 Using Annoy for neighbor search, n_neighbors = 30
21:35:51 Building Annoy index with metric = cosine, n_trees = 50
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:35:57 Writing NN index file to temp file C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\file99183d6114db
21:35:57 Searching Annoy index using 1 thread, search_k = 3000
21:36:13 Annoy recall = 100%
21:36:16 Commencing smooth kNN distance calibration using 1 thread with target n_neighbors = 30
21:36:23 Initializing from normalized Laplacian + noise (using RSpectra)
21:36:24 Commencing optimization for 200 epochs, with 708728 positive edges
Using method 'umap'
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:37:10 Optimization finished
hm.integrated <- FindNeighbors(hm.integrated, reduction = "harmony", dims = 1:30)
Computing nearest neighbor graph
Computing SNN
hm.integrated <- FindClusters(hm.integrated, resolution = 0.5)
Modularity Optimizer version 1.3.0 by Ludo Waltman and Nees Jan van Eck
Number of nodes: 18642
Number of edges: 388059
Running Louvain algorithm...
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
Maximum modularity in 10 random starts: 0.7960
Number of communities: 17
Elapsed time: 5 seconds
2 singletons identified. 15 final clusters.
p2<-DimPlot(hm.integrated,reduction="umap",group.by='seurat_clusters',label=TRUE,pt.size=0.1)+NoLegend()
save(hm.integrated,file="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/hm_integrated.RData")
selected_clusters <- c(0, 1, 2, 3)
cells_to_keep <- WhichCells(hm.integrated, idents = selected_clusters)
filtered_hm.integrated <- subset(hm.integrated, cells = cells_to_keep)
save(filtered_hm.integrated, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/filtered_hm_integrated.RData")
p_filtered <- DimPlot(filtered_hm.integrated, reduction = "umap", group.by = 'seurat_clusters', label = TRUE, pt.size = 0.1) + NoLegend()
print(p_filtered)
filtered_allele1<-subset(filtered_hm.integrated, dataset == "allele1")
filtered_allele2<-subset(filtered_hm.integrated, dataset == "allele2")
library(GenomicRanges)
async_master_list_path <- "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/async_master_list.GRCm38.noX[6776].bed"
filtered_allele1_counts <-filtered_allele1[["peaks"]]@counts
peaks <- row.names(filtered_allele1_counts)
# Create a new data frame using lapply for efficiency
peaks.df <- as.data.frame(do.call(rbind, lapply(peaks, function(x) unlist(strsplit(x, "[:-]")))))
# Set column names
colnames(peaks.df) <- c("seqnames", "start", "end")
peaks.gr <- makeGRangesFromDataFrame(peaks.df)
asrt <- read.delim(async_master_list_path, header = F, col.names = c("seqnames", "start", "end", "ASRT"))
asrt$seqnames <- gsub("chr", "", asrt$seqnames)
asrt.gr <- makeGRangesFromDataFrame(asrt)
overlaps <- findOverlaps(peaks.gr, asrt.gr)
peaks.overlap.asrt <- subsetByOverlaps(peaks.gr, asrt.gr, type="any")
peaks.overlap.asrt.names = paste(peaks.overlap.asrt@seqnames, peaks.overlap.asrt@ranges, sep="-")
counts.asrt <- filtered_allele1_counts[row.names(filtered_allele1_counts) %in% peaks.overlap.asrt.names,]
rownames(counts.asrt) <- rownames(counts.asrt)
filtered_allele1 <- subset(filtered_allele1, features = rownames(counts.asrt))
filtered_allele1[["peaks"]]@counts <- counts.asrt
dim(filtered_allele1[["peaks"]]@counts)
[1] 12690 7161
#normalisation
filtered_allele1<- RunTFIDF(filtered_allele1)
Performing TF-IDF normalization
Warning in RunTFIDF.default(object = GetAssayData(object = object, slot = "counts"), :
Some features contain 0 total counts
filtered_allele1 <- FindTopFeatures(filtered_allele1, min.cutoff = 'q0')
filtered_allele1 <- RunSVD(filtered_allele1)
Running SVD
Scaling cell embeddings
filtered_allele1 <- RunUMAP(filtered_allele1, reduction = "lsi", dims = 1:30)
21:45:50 UMAP embedding parameters a = 0.9922 b = 1.112
21:45:50 Read 7161 rows and found 30 numeric columns
21:45:50 Using Annoy for neighbor search, n_neighbors = 30
21:45:50 Building Annoy index with metric = cosine, n_trees = 50
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:45:53 Writing NN index file to temp file C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\file99186e8b1714
21:45:53 Searching Annoy index using 1 thread, search_k = 3000
21:45:58 Annoy recall = 100%
21:46:21 Commencing smooth kNN distance calibration using 1 thread with target n_neighbors = 30
21:46:26 Initializing from normalized Laplacian + noise (using RSpectra)
21:46:26 Commencing optimization for 500 epochs, with 238618 positive edges
Using method 'umap'
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:47:09 Optimization finished
async_master_list_path <- "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/async_master_list.GRCm38.noX[6776].bed"
filtered_allele2_counts <-filtered_allele2[["peaks"]]@counts
peaks <- row.names(filtered_allele2_counts)
peaks.df <- as.data.frame(do.call(rbind, lapply(peaks, function(x) unlist(strsplit(x, "[:-]")))))
# Set column names
colnames(peaks.df) <- c("seqnames", "start", "end")
peaks.gr <- makeGRangesFromDataFrame(peaks.df)
asrt <- read.delim(async_master_list_path, header = F, col.names = c("seqnames", "start", "end", "ASRT"))
asrt$seqnames <- gsub("chr", "", asrt$seqnames)
asrt.gr <- makeGRangesFromDataFrame(asrt)
overlaps <- findOverlaps(peaks.gr, asrt.gr)
peaks.overlap.asrt <- subsetByOverlaps(peaks.gr, asrt.gr, type="any")
peaks.overlap.asrt.names = paste(peaks.overlap.asrt@seqnames, peaks.overlap.asrt@ranges, sep="-")
counts.asrt <- filtered_allele2_counts[row.names(filtered_allele2_counts) %in% peaks.overlap.asrt.names,]
rownames(counts.asrt) <- rownames(counts.asrt)
filtered_allele2 <- subset(filtered_allele2, features = rownames(counts.asrt))
filtered_allele2[["peaks"]]@counts <- counts.asrt
dim(filtered_allele2[["peaks"]]@counts)
[1] 12690 7897
#normalisation
filtered_allele2<- RunTFIDF(filtered_allele2)
Performing TF-IDF normalization
Warning in RunTFIDF.default(object = GetAssayData(object = object, slot = "counts"), :
Some features contain 0 total counts
filtered_allele2 <- FindTopFeatures(filtered_allele2, min.cutoff = 'q0')
filtered_allele2 <- RunSVD(filtered_allele2)
Running SVD
Scaling cell embeddings
filtered_allele2 <- RunUMAP(filtered_allele2, reduction = "lsi", dims = 1:30)
21:49:03 UMAP embedding parameters a = 0.9922 b = 1.112
21:49:03 Read 7897 rows and found 30 numeric columns
21:49:03 Using Annoy for neighbor search, n_neighbors = 30
21:49:03 Building Annoy index with metric = cosine, n_trees = 50
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:49:05 Writing NN index file to temp file C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\file99185ec97246
21:49:05 Searching Annoy index using 1 thread, search_k = 3000
21:49:11 Annoy recall = 100%
21:49:14 Commencing smooth kNN distance calibration using 1 thread with target n_neighbors = 30
21:49:20 Initializing from normalized Laplacian + noise (using RSpectra)
21:49:20 Commencing optimization for 500 epochs, with 261906 positive edges
Using method 'umap'
0% 10 20 30 40 50 60 70 80 90 100%
[----|----|----|----|----|----|----|----|----|----|
**************************************************|
21:50:06 Optimization finished
# Hierarchical clustering
hc <- hclust(dist(Embeddings(filtered_allele2, "umap")))
clusters <- cutree(hc, k = 2) # Adjust k as needed
# K-means
km <- kmeans(Embeddings(filtered_allele2, "umap"), centers = 2) # Adjust centers as needed
clusters<-km$cluster
filtered_allele2$hierarchical_clusters <- as.factor(clusters)
DimPlot(filtered_allele2, reduction = "umap", group.by = "hierarchical_clusters", label = TRUE, pt.size = 0.5)
cluster_id <- "hierarchical_clusters"
markers<- FindMarkers(filtered_allele2, ident.1 = 1, ident.2 = 2, test.use = "wilcox", latent.vars = cluster_id)
Warning: 'latent.vars' is only used for the following tests: negbinom, poisson, MAST, LR
| | 0 % ~calculating
|+ | 1 % ~01m 01s
|++ | 2 % ~01m 01s
|++ | 3 % ~01m 01s
|+++ | 4 % ~01m 01s
|+++ | 5 % ~01m 01s
|++++ | 6 % ~01m 01s
|++++ | 7 % ~60s
|+++++ | 8 % ~58s
|+++++ | 9 % ~57s
|++++++ | 10% ~57s
|++++++ | 11% ~56s
|+++++++ | 12% ~56s
|+++++++ | 13% ~55s
|++++++++ | 14% ~54s
|++++++++ | 15% ~54s
|+++++++++ | 16% ~54s
|+++++++++ | 17% ~55s
|++++++++++ | 18% ~55s
|++++++++++ | 19% ~54s
|+++++++++++ | 20% ~54s
|+++++++++++ | 21% ~53s
|++++++++++++ | 22% ~52s
|++++++++++++ | 23% ~51s
|+++++++++++++ | 24% ~50s
|+++++++++++++ | 26% ~50s
|++++++++++++++ | 27% ~49s
|++++++++++++++ | 28% ~48s
|+++++++++++++++ | 29% ~47s
|+++++++++++++++ | 30% ~47s
|++++++++++++++++ | 31% ~46s
|++++++++++++++++ | 32% ~45s
|+++++++++++++++++ | 33% ~45s
|+++++++++++++++++ | 34% ~44s
|++++++++++++++++++ | 35% ~44s
|++++++++++++++++++ | 36% ~43s
|+++++++++++++++++++ | 37% ~43s
|+++++++++++++++++++ | 38% ~42s
|++++++++++++++++++++ | 39% ~41s
|++++++++++++++++++++ | 40% ~40s
|+++++++++++++++++++++ | 41% ~40s
|+++++++++++++++++++++ | 42% ~39s
|++++++++++++++++++++++ | 43% ~38s
|++++++++++++++++++++++ | 44% ~38s
|+++++++++++++++++++++++ | 45% ~37s
|+++++++++++++++++++++++ | 46% ~36s
|++++++++++++++++++++++++ | 47% ~36s
|++++++++++++++++++++++++ | 48% ~35s
|+++++++++++++++++++++++++ | 49% ~34s
|+++++++++++++++++++++++++ | 50% ~34s
|++++++++++++++++++++++++++ | 51% ~33s
|+++++++++++++++++++++++++++ | 52% ~32s
|+++++++++++++++++++++++++++ | 53% ~31s
|++++++++++++++++++++++++++++ | 54% ~31s
|++++++++++++++++++++++++++++ | 55% ~30s
|+++++++++++++++++++++++++++++ | 56% ~30s
|+++++++++++++++++++++++++++++ | 57% ~29s
|++++++++++++++++++++++++++++++ | 58% ~28s
|++++++++++++++++++++++++++++++ | 59% ~27s
|+++++++++++++++++++++++++++++++ | 60% ~27s
|+++++++++++++++++++++++++++++++ | 61% ~26s
|++++++++++++++++++++++++++++++++ | 62% ~25s
|++++++++++++++++++++++++++++++++ | 63% ~24s
|+++++++++++++++++++++++++++++++++ | 64% ~24s
|+++++++++++++++++++++++++++++++++ | 65% ~23s
|++++++++++++++++++++++++++++++++++ | 66% ~22s
|++++++++++++++++++++++++++++++++++ | 67% ~22s
|+++++++++++++++++++++++++++++++++++ | 68% ~21s
|+++++++++++++++++++++++++++++++++++ | 69% ~20s
|++++++++++++++++++++++++++++++++++++ | 70% ~20s
|++++++++++++++++++++++++++++++++++++ | 71% ~19s
|+++++++++++++++++++++++++++++++++++++ | 72% ~18s
|+++++++++++++++++++++++++++++++++++++ | 73% ~17s
|++++++++++++++++++++++++++++++++++++++ | 74% ~17s
|++++++++++++++++++++++++++++++++++++++ | 76% ~16s
|+++++++++++++++++++++++++++++++++++++++ | 77% ~15s
|+++++++++++++++++++++++++++++++++++++++ | 78% ~15s
|++++++++++++++++++++++++++++++++++++++++ | 79% ~14s
|++++++++++++++++++++++++++++++++++++++++ | 80% ~13s
|+++++++++++++++++++++++++++++++++++++++++ | 81% ~13s
|+++++++++++++++++++++++++++++++++++++++++ | 82% ~12s
|++++++++++++++++++++++++++++++++++++++++++ | 83% ~11s
|++++++++++++++++++++++++++++++++++++++++++ | 84% ~11s
|+++++++++++++++++++++++++++++++++++++++++++ | 85% ~10s
|+++++++++++++++++++++++++++++++++++++++++++ | 86% ~09s
|++++++++++++++++++++++++++++++++++++++++++++ | 87% ~09s
|++++++++++++++++++++++++++++++++++++++++++++ | 88% ~08s
|+++++++++++++++++++++++++++++++++++++++++++++ | 89% ~07s
|+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~07s
|++++++++++++++++++++++++++++++++++++++++++++++ | 91% ~06s
|++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~05s
|+++++++++++++++++++++++++++++++++++++++++++++++ | 93% ~05s
|+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~04s
|++++++++++++++++++++++++++++++++++++++++++++++++ | 95% ~03s
|++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~03s
|+++++++++++++++++++++++++++++++++++++++++++++++++ | 97% ~02s
|+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~01s
|++++++++++++++++++++++++++++++++++++++++++++++++++| 99% ~01s
|++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=01m 04s
head(markers)
write.table(markers, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/Markersgenome2.bed",sep = "\t", row.names = FALSE, col.names = FALSE, quote = FALSE)
significant_markers2<- markers[markers$p_val_adj < 0.05, ]
num_significant_genes2<- nrow(significant_markers2)
print(num_significant_genes2)
[1] 142
gene_list2 <- rownames(significant_markers2)
coords <- strsplit(row.names(significant_markers1), "-")
bed <- do.call(rbind, lapply(coords, function(x) {
c(paste0("chr", x[1]), as.numeric(x[2]), as.numeric(x[3]))
}))
bed <- as.data.frame(bed, stringsAsFactors = FALSE)
colnames(bed) <- c("chrom", "chromStart", "chromEnd")
bed$score <- significant_markers1$p_val_adj
bed$chromStart <- as.numeric(bed$chromStart)
bed$chromEnd <- as.numeric(bed$chromEnd)
write.table(bed, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/markers_genome1.bed",sep = "\t", row.names = FALSE, col.names = FALSE, quote = FALSE)
coords <- strsplit(row.names(significant_markers2), "-")
bed <- do.call(rbind, lapply(coords, function(x) {
c(paste0("chr", x[1]), as.numeric(x[2]), as.numeric(x[3]))
}))
bed <- as.data.frame(bed, stringsAsFactors = FALSE)
colnames(bed) <- c("chrom", "chromStart", "chromEnd")
bed$score <- significant_markers2$p_val_adj
bed$chromStart <- as.numeric(bed$chromStart)
bed$chromEnd <- as.numeric(bed$chromEnd)
# Écrire dans un fichier BED
write.table(bed, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome2/markers_genome2.bed",sep = "\t", row.names = FALSE, col.names = FALSE, quote = FALSE)
library(ensembldb)
library(rtracklayer)
library(EnsDb.Mmusculus.v79)
if (!requireNamespace("BiocManager", quietly = TRUE))
install.packages("BiocManager")
BiocManager::install("ensembldb")
'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for
details.
Replacement repositories:
CRAN: https://cran.rstudio.com/
Bioconductor version 3.18 (BiocManager 1.30.23), R 4.3.2 (2023-10-31 ucrt)
Warning: package(s) not installed when version(s) same as or greater than current; use `force = TRUE` to re-install: 'ensembldb'
Installation paths not writeable, unable to update packages
path: C:/Program Files/R/R-4.3.2/library
packages:
boot, cluster, codetools, foreign, KernSmooth, lattice, mgcv, nlme, rpart, survival
Old packages: 'BiocManager', 'bitops', 'cli', 'colorspace', 'cpp11', 'curl', 'data.table', 'digest', 'ggfun', 'harmony', 'RANN',
'Rcpp', 'RCurl', 'rlang', 'scatterpie', 'Signac', 'sp', 'stringi', 'xfun', 'yaml', 'yulab.utils'
Update all/some/none? [a/s/n]:
a
Warning: packages 'harmony', 'Rcpp', 'Signac', 'sp' are in use and will not be installed
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/BiocManager_1.30.25.zip'
Content type 'application/zip' length 504477 bytes (492 KB)
downloaded 492 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/bitops_1.0-8.zip'
Content type 'application/zip' length 32116 bytes (31 KB)
downloaded 31 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/cli_3.6.3.zip'
Content type 'application/zip' length 1338103 bytes (1.3 MB)
downloaded 1.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/colorspace_2.1-1.zip'
Content type 'application/zip' length 2659905 bytes (2.5 MB)
downloaded 2.5 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/cpp11_0.5.0.zip'
Content type 'application/zip' length 293782 bytes (286 KB)
downloaded 286 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/curl_5.2.2.zip'
Content type 'application/zip' length 3217772 bytes (3.1 MB)
downloaded 3.1 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/data.table_1.16.0.zip'
Content type 'application/zip' length 2446496 bytes (2.3 MB)
downloaded 2.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/digest_0.6.37.zip'
Content type 'application/zip' length 221744 bytes (216 KB)
downloaded 216 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/ggfun_0.1.6.zip'
Content type 'application/zip' length 213206 bytes (208 KB)
downloaded 208 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/RANN_2.6.2.zip'
Content type 'application/zip' length 366879 bytes (358 KB)
downloaded 358 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/RCurl_1.98-1.16.zip'
Content type 'application/zip' length 4917699 bytes (4.7 MB)
downloaded 4.7 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/rlang_1.1.4.zip'
Content type 'application/zip' length 1580231 bytes (1.5 MB)
downloaded 1.5 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/scatterpie_0.2.4.zip'
Content type 'application/zip' length 151579 bytes (148 KB)
downloaded 148 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/stringi_1.8.4.zip'
Content type 'application/zip' length 14997376 bytes (14.3 MB)
downloaded 14.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/xfun_0.47.zip'
Content type 'application/zip' length 534613 bytes (522 KB)
downloaded 522 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/yaml_2.3.10.zip'
Content type 'application/zip' length 118410 bytes (115 KB)
downloaded 115 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/yulab.utils_0.1.7.zip'
Content type 'application/zip' length 109382 bytes (106 KB)
downloaded 106 KB
package 'BiocManager' successfully unpacked and MD5 sums checked
package 'bitops' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'bitops'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\bitops\libs\x64\bitops.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\bitops\libs\x64\bitops.dll: Permission denied
Warning: restored 'bitops'
package 'cli' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'cli'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\cli\libs\x64\cli.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\cli\libs\x64\cli.dll: Permission denied
Warning: restored 'cli'
package 'colorspace' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'colorspace'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\colorspace\libs\x64\colorspace.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\colorspace\libs\x64\colorspace.dll: Permission denied
Warning: restored 'colorspace'
package 'cpp11' successfully unpacked and MD5 sums checked
package 'curl' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'curl'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\curl\libs\x64\curl.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\curl\libs\x64\curl.dll: Permission denied
Warning: restored 'curl'
package 'data.table' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'data.table'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\data.table\libs\x64\data_table.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\data.table\libs\x64\data_table.dll: Permission denied
Warning: restored 'data.table'
package 'digest' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'digest'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\digest\libs\x64\digest.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\digest\libs\x64\digest.dll: Permission denied
Warning: restored 'digest'
package 'ggfun' successfully unpacked and MD5 sums checked
package 'RANN' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'RANN'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\RANN\libs\x64\RANN.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\RANN\libs\x64\RANN.dll: Permission denied
Warning: restored 'RANN'
package 'RCurl' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'RCurl'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\RCurl\libs\x64\RCurl.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\RCurl\libs\x64\RCurl.dll: Permission denied
Warning: restored 'RCurl'
package 'rlang' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'rlang'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\rlang\libs\x64\rlang.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\rlang\libs\x64\rlang.dll: Permission denied
Warning: restored 'rlang'
package 'scatterpie' successfully unpacked and MD5 sums checked
package 'stringi' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'stringi'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\stringi\libs\x64\stringi.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\stringi\libs\x64\stringi.dll: Permission denied
Warning: restored 'stringi'
package 'xfun' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'xfun'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\xfun\libs\x64\xfun.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\xfun\libs\x64\xfun.dll: Permission denied
Warning: restored 'xfun'
package 'yaml' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'yaml'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\yaml\libs\x64\yaml.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\yaml\libs\x64\yaml.dll: Permission denied
Warning: restored 'yaml'
package 'yulab.utils' successfully unpacked and MD5 sums checked
The downloaded binary packages are in
C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\downloaded_packages
BiocManager::install("AnnotationHub")
'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for
details.
Replacement repositories:
CRAN: https://cran.rstudio.com/
Bioconductor version 3.18 (BiocManager 1.30.25), R 4.3.2 (2023-10-31 ucrt)
Warning: package(s) not installed when version(s) same as or greater than current; use `force = TRUE` to re-install: 'AnnotationHub'
Installation paths not writeable, unable to update packages
path: C:/Program Files/R/R-4.3.2/library
packages:
boot, cluster, codetools, foreign, KernSmooth, lattice, mgcv, nlme, rpart, survival
Old packages: 'bitops', 'cli', 'colorspace', 'curl', 'data.table', 'digest', 'harmony', 'RANN', 'Rcpp', 'RCurl', 'rlang',
'Signac', 'sp', 'stringi', 'xfun', 'yaml'
Update all/some/none? [a/s/n]:
a
Warning: packages 'harmony', 'Rcpp', 'Signac', 'sp' are in use and will not be installed
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/bitops_1.0-8.zip'
Content type 'application/zip' length 32116 bytes (31 KB)
downloaded 31 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/cli_3.6.3.zip'
Content type 'application/zip' length 1338103 bytes (1.3 MB)
downloaded 1.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/colorspace_2.1-1.zip'
Content type 'application/zip' length 2659905 bytes (2.5 MB)
downloaded 2.5 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/curl_5.2.2.zip'
Content type 'application/zip' length 3217772 bytes (3.1 MB)
downloaded 3.1 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/data.table_1.16.0.zip'
Content type 'application/zip' length 2446496 bytes (2.3 MB)
downloaded 2.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/digest_0.6.37.zip'
Content type 'application/zip' length 221744 bytes (216 KB)
downloaded 216 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/RANN_2.6.2.zip'
Content type 'application/zip' length 366879 bytes (358 KB)
downloaded 358 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/RCurl_1.98-1.16.zip'
Content type 'application/zip' length 4917699 bytes (4.7 MB)
downloaded 4.7 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/rlang_1.1.4.zip'
Content type 'application/zip' length 1580231 bytes (1.5 MB)
downloaded 1.5 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/stringi_1.8.4.zip'
Content type 'application/zip' length 14997376 bytes (14.3 MB)
downloaded 14.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/xfun_0.47.zip'
Content type 'application/zip' length 534613 bytes (522 KB)
downloaded 522 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/yaml_2.3.10.zip'
Content type 'application/zip' length 118410 bytes (115 KB)
downloaded 115 KB
package 'bitops' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'bitops'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\bitops\libs\x64\bitops.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\bitops\libs\x64\bitops.dll: Permission denied
Warning: restored 'bitops'
package 'cli' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'cli'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\cli\libs\x64\cli.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\cli\libs\x64\cli.dll: Permission denied
Warning: restored 'cli'
package 'colorspace' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'colorspace'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\colorspace\libs\x64\colorspace.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\colorspace\libs\x64\colorspace.dll: Permission denied
Warning: restored 'colorspace'
package 'curl' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'curl'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\curl\libs\x64\curl.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\curl\libs\x64\curl.dll: Permission denied
Warning: restored 'curl'
package 'data.table' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'data.table'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\data.table\libs\x64\data_table.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\data.table\libs\x64\data_table.dll: Permission denied
Warning: restored 'data.table'
package 'digest' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'digest'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\digest\libs\x64\digest.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\digest\libs\x64\digest.dll: Permission denied
Warning: restored 'digest'
package 'RANN' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'RANN'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\RANN\libs\x64\RANN.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\RANN\libs\x64\RANN.dll: Permission denied
Warning: restored 'RANN'
package 'RCurl' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'RCurl'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\RCurl\libs\x64\RCurl.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\RCurl\libs\x64\RCurl.dll: Permission denied
Warning: restored 'RCurl'
package 'rlang' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'rlang'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\rlang\libs\x64\rlang.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\rlang\libs\x64\rlang.dll: Permission denied
Warning: restored 'rlang'
package 'stringi' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'stringi'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\stringi\libs\x64\stringi.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\stringi\libs\x64\stringi.dll: Permission denied
Warning: restored 'stringi'
package 'xfun' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'xfun'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\xfun\libs\x64\xfun.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\xfun\libs\x64\xfun.dll: Permission denied
Warning: restored 'xfun'
package 'yaml' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'yaml'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\yaml\libs\x64\yaml.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\yaml\libs\x64\yaml.dll: Permission denied
Warning: restored 'yaml'
The downloaded binary packages are in
C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\downloaded_packages
BiocManager::install("EnsDb.Mmusculus.v79")
'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for
details.
Replacement repositories:
CRAN: https://cran.rstudio.com/
Bioconductor version 3.18 (BiocManager 1.30.25), R 4.3.2 (2023-10-31 ucrt)
Warning: package(s) not installed when version(s) same as or greater than current; use `force = TRUE` to re-install: 'EnsDb.Mmusculus.v79'
Installation paths not writeable, unable to update packages
path: C:/Program Files/R/R-4.3.2/library
packages:
boot, cluster, codetools, foreign, KernSmooth, lattice, mgcv, nlme, rpart, survival
Old packages: 'bitops', 'cli', 'colorspace', 'curl', 'data.table', 'digest', 'harmony', 'RANN', 'Rcpp', 'RCurl', 'rlang',
'Signac', 'sp', 'stringi', 'xfun', 'yaml'
Update all/some/none? [a/s/n]:
a
Warning: packages 'harmony', 'Rcpp', 'Signac', 'sp' are in use and will not be installed
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/bitops_1.0-8.zip'
Content type 'application/zip' length 32116 bytes (31 KB)
downloaded 31 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/cli_3.6.3.zip'
Content type 'application/zip' length 1338103 bytes (1.3 MB)
downloaded 1.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/colorspace_2.1-1.zip'
Content type 'application/zip' length 2659905 bytes (2.5 MB)
downloaded 2.5 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/curl_5.2.2.zip'
Content type 'application/zip' length 3217772 bytes (3.1 MB)
downloaded 3.1 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/data.table_1.16.0.zip'
Content type 'application/zip' length 2446496 bytes (2.3 MB)
downloaded 2.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/digest_0.6.37.zip'
Content type 'application/zip' length 221744 bytes (216 KB)
downloaded 216 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/RANN_2.6.2.zip'
Content type 'application/zip' length 366879 bytes (358 KB)
downloaded 358 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/RCurl_1.98-1.16.zip'
Content type 'application/zip' length 4917699 bytes (4.7 MB)
downloaded 4.7 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/rlang_1.1.4.zip'
Content type 'application/zip' length 1580231 bytes (1.5 MB)
downloaded 1.5 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/stringi_1.8.4.zip'
Content type 'application/zip' length 14997376 bytes (14.3 MB)
downloaded 14.3 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/xfun_0.47.zip'
Content type 'application/zip' length 534613 bytes (522 KB)
downloaded 522 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.3/yaml_2.3.10.zip'
Content type 'application/zip' length 118410 bytes (115 KB)
downloaded 115 KB
package 'bitops' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'bitops'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\bitops\libs\x64\bitops.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\bitops\libs\x64\bitops.dll: Permission denied
Warning: restored 'bitops'
package 'cli' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'cli'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\cli\libs\x64\cli.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\cli\libs\x64\cli.dll: Permission denied
Warning: restored 'cli'
package 'colorspace' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'colorspace'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\colorspace\libs\x64\colorspace.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\colorspace\libs\x64\colorspace.dll: Permission denied
Warning: restored 'colorspace'
package 'curl' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'curl'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\curl\libs\x64\curl.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\curl\libs\x64\curl.dll: Permission denied
Warning: restored 'curl'
package 'data.table' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'data.table'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\data.table\libs\x64\data_table.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\data.table\libs\x64\data_table.dll: Permission denied
Warning: restored 'data.table'
package 'digest' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'digest'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\digest\libs\x64\digest.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\digest\libs\x64\digest.dll: Permission denied
Warning: restored 'digest'
package 'RANN' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'RANN'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\RANN\libs\x64\RANN.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\RANN\libs\x64\RANN.dll: Permission denied
Warning: restored 'RANN'
package 'RCurl' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'RCurl'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\RCurl\libs\x64\RCurl.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\RCurl\libs\x64\RCurl.dll: Permission denied
Warning: restored 'RCurl'
package 'rlang' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'rlang'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\rlang\libs\x64\rlang.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\rlang\libs\x64\rlang.dll: Permission denied
Warning: restored 'rlang'
package 'stringi' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'stringi'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\stringi\libs\x64\stringi.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\stringi\libs\x64\stringi.dll: Permission denied
Warning: restored 'stringi'
package 'xfun' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'xfun'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\xfun\libs\x64\xfun.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\xfun\libs\x64\xfun.dll: Permission denied
Warning: restored 'xfun'
package 'yaml' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'yaml'
Warning in file.copy(savedcopy, lib, recursive = TRUE) :
problem copying C:\Users\helper\AppData\Local\R\win-library\4.3\00LOCK\yaml\libs\x64\yaml.dll to C:\Users\helper\AppData\Local\R\win-library\4.3\yaml\libs\x64\yaml.dll: Permission denied
Warning: restored 'yaml'
The downloaded binary packages are in
C:\Users\helper\AppData\Local\Temp\Rtmpktlz1U\downloaded_packages
ensdb <- EnsDb.Mmusculus.v79
gr <- genes(ensdb)
export(gr, format = "gff3", con = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/EnsDb.Mmusculus.v79.gff3")
library("ChIPseeker")
library("EnsDb.Mmusculus.v79")
txdb <- EnsDb.Mmusculus.v79
library("org.Mm.eg.db")
library("clusterProfiler")
peaks1<- readPeakFile("C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/markers_genome1.bed")
#write.table(peaks, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/markers_peaks.txt",sep = "\t", row.names = FALSE, col.names = FALSE, quote = FALSE)
seqlevels(peaks1) <- gsub("^chr", "", seqlevels(peaks1))
peakAnno <- annotatePeak(peaks1,tssRegion = c(1000,3000),TxDb=txdb,annoDb="org.Mm.eg.db")
>> preparing features information... 2024-08-29 11:11:28
>> identifying nearest features... 2024-08-29 11:11:28
>> calculating distance from peak to TSS... 2024-08-29 11:11:29
>> assigning genomic annotation... 2024-08-29 11:11:29
>> adding gene annotation... 2024-08-29 11:11:32
'select()' returned 1:1 mapping between keys and columns
>> assigning chromosome lengths 2024-08-29 11:11:32
>> done... 2024-08-29 11:11:32
plotAnnoPie(peakAnno)
# Extraire les gènes associés
anno_data <- as.data.frame(peakAnno)
# Vérifier les colonnes disponibles
head(anno_data)
# Filtrer les gènes uniques
unique_genes <- unique(anno_data$geneId)
# Compter le nombre total de gènes uniques
total_genes <- length(unique_genes)
total_genes
[1] 85
#library(biomaRt)
#ensembl <- useMart ("ensembl",dataset=musculus_gene_ensembl)
#gene_info <-getBM(attributes="C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome1/markers_genome1.bed",filters=')
#Accéder aux donnéesdannotation
anno<- peakAnno@anno
gene_names<-anno$SYMBOL
write.table(gene_names, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/allgenesmarker1.txt",sep = "\t", row.names = FALSE, col.names = FALSE, quote = FALSE)
library("ChIPseeker")
library("EnsDb.Mmusculus.v79")
txdb <- EnsDb.Mmusculus.v79
library("org.Mm.eg.db")
library("clusterProfiler")
peaks2<- readPeakFile("C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/genome2/markers_genome2.bed")
#write.table(peaks, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/markers_peaks.txt",sep = "\t", row.names = FALSE, col.names = FALSE, quote = FALSE)
seqlevels(peaks2) <- gsub("^chr", "", seqlevels(peaks2))
peakAnno <- annotatePeak(peaks2,tssRegion = c(1000,3000),TxDb=txdb,annoDb="org.Mm.eg.db")
>> preparing features information... 2024-08-29 10:10:03
>> identifying nearest features... 2024-08-29 10:10:03
>> calculating distance from peak to TSS... 2024-08-29 10:10:03
>> assigning genomic annotation... 2024-08-29 10:10:03
>> adding gene annotation... 2024-08-29 10:10:05
'select()' returned 1:many mapping between keys and columns
>> assigning chromosome lengths 2024-08-29 10:10:05
>> done... 2024-08-29 10:10:05
plotAnnoPie(peakAnno)
# Accéder aux données d'annotation
anno<- peakAnno@anno
gene_names<-anno$SYMBOL
write.table(gene_names, file = "C:/Users/helper/Documents/yofith/fichiersprojetsbioinfo/allgenesmarker2.txt",sep = "\t", row.names = FALSE, col.names = FALSE, quote = FALSE)
```
Add a new chunk by clicking the Insert Chunk button on the toolbar or by pressing Ctrl+Alt+I.
When you save the notebook, an HTML file containing the code and output will be saved alongside it (click the Preview button or press Ctrl+Shift+K to preview the HTML file).
The preview shows you a rendered HTML copy of the contents of the editor. Consequently, unlike Knit, Preview does not run any R code chunks. Instead, the output of the chunk when it was last run in the editor is displayed.