From 3017ddea5c0a33b676964547826fe15869fb0d10 Mon Sep 17 00:00:00 2001
From: js2264
-hic <- import(
- "path/to/contact_matrix.cool",
+## Change <path/to/contact_matrix>.cool accordingly
+hic <- import(
+ "<path/to/contact_matrix>.cool",
focus = "chr:start-end",
resolution = ...
)
getters
:
fileName(hic)
-#> [1] "/github/home/.cache/R/ExperimentHub/5317591363eb_7752"
+#> [1] "/github/home/.cache/R/ExperimentHub/118f28b9daf_7752"
focus(hic)
#> [1] "II:1-800000"
resolutions(hic)
@@ -641,7 +642,7 @@ Scores
#> List of length 3
#> names(3): count balanced random
tail(scores(hic, 'random'))
-#> [1] 0.2556651 0.7672956 0.9362329 0.1011628 0.1509242 0.7743407
HiCExperiment
#> [33479] II 798001-800000 --- II 798001-800000 | 515
#> bin_id2 count balanced random
#> <numeric> <numeric> <numeric> <numeric>
-#> [1] 116 1 NaN 0.4817893
-#> [2] 118 2 NaN 0.0724057
-#> [3] 119 3 NaN 0.8441706
-#> [4] 120 15 NaN 0.3689550
-#> [5] 121 9 NaN 0.5207708
+#> [1] 116 1 NaN 0.167110
+#> [2] 118 2 NaN 0.259684
+#> [3] 119 3 NaN 0.491863
+#> [4] 120 15 NaN 0.250041
+#> [5] 121 9 NaN 0.404962
#> ... ... ... ... ...
-#> [33475] 514 309 0.1194189 0.767296
-#> [33476] 515 227 0.0956207 0.936233
-#> [33477] 514 130 0.0501703 0.101163
-#> [33478] 515 297 0.1249314 0.150924
-#> [33479] 515 117 0.0536429 0.774341
+#> [33475] 514 309 0.1194189 0.462820
+#> [33476] 515 227 0.0956207 0.242721
+#> [33477] 514 130 0.0501703 0.127333
+#> [33478] 515 297 0.1249314 0.774970
+#> [33479] 515 117 0.0536429 0.949664
#> -------
#> regions: 400 ranges and 4 metadata columns
#> seqinfo: 16 sequences from an unspecified genome
@@ -709,29 +710,28 @@ HiCExperiment
#> metadata(0):
#> regions: 400
as(hic, "matrix")[1:10, 1:10]
-#> 10 x 10 sparse Matrix of class "dgTMatrix"
-#>
-#> [1,] NaN . NaN NaN NaN NaN NaN NaN NaN
-#> [2,] . . . . . . . . .
-#> [3,] NaN . . NaN NaN NaN NaN NaN NaN
-#> [4,] NaN . NaN NaN NaN NaN NaN NaN NaN
-#> [5,] NaN . NaN NaN 0.08079721 0.18680431 0.13127403 0.08833001 0.06759757
-#> [6,] NaN . NaN NaN 0.18680431 0.08183011 0.19176749 0.12687633 0.10078115
-#> [7,] NaN . NaN NaN 0.13127403 0.19176749 0.08040523 0.13690173 0.13249106
-#> [8,] NaN . NaN NaN 0.08833001 0.12687633 0.13690173 0.07977117 0.18151495
-#> [9,] NaN . NaN NaN 0.06759757 0.10078115 0.13249106 0.18151495 0.06494950
-#> [10,] NaN . NaN NaN 0.06021225 0.07728955 0.09404388 0.12720548 0.11622354
-#>
-#> [1,] NaN
-#> [2,] .
-#> [3,] NaN
-#> [4,] NaN
-#> [5,] 0.06021225
-#> [6,] 0.07728955
-#> [7,] 0.09404388
-#> [8,] 0.12720548
-#> [9,] 0.11622354
-#> [10,] 0.06796588
+#> [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8]
+#> [1,] NaN 0 NaN NaN NaN NaN NaN NaN
+#> [2,] 0 0 0 0 0.00000000 0.00000000 0.00000000 0.00000000
+#> [3,] NaN 0 0 NaN NaN NaN NaN NaN
+#> [4,] NaN 0 NaN NaN NaN NaN NaN NaN
+#> [5,] NaN 0 NaN NaN 0.08079721 0.18680431 0.13127403 0.08833001
+#> [6,] NaN 0 NaN NaN 0.18680431 0.08183011 0.19176749 0.12687633
+#> [7,] NaN 0 NaN NaN 0.13127403 0.19176749 0.08040523 0.13690173
+#> [8,] NaN 0 NaN NaN 0.08833001 0.12687633 0.13690173 0.07977117
+#> [9,] NaN 0 NaN NaN 0.06759757 0.10078115 0.13249106 0.18151495
+#> [10,] NaN 0 NaN NaN 0.06021225 0.07728955 0.09404388 0.12720548
+#> [,9] [,10]
+#> [1,] NaN NaN
+#> [2,] 0.00000000 0.00000000
+#> [3,] NaN NaN
+#> [4,] NaN NaN
+#> [5,] 0.06759757 0.06021225
+#> [6,] 0.10078115 0.07728955
+#> [7,] 0.13249106 0.09404388
+#> [8,] 0.18151495 0.12720548
+#> [9,] 0.06494950 0.11622354
+#> [10,] 0.11622354 0.06796588
as(hic, "data.frame")[1:10, ]
#> seqnames1 start1 end1 width1 strand1 bin_id1 weight1 center1 seqnames2
#> 1 II 1 2000 2000 * 116 NaN 1000 II
@@ -756,16 +756,16 @@ HiCExperiment
#> 9 18001 20000 2000 * 125 0.02331795 19000 6 NaN
#> 10 20001 22000 2000 * 126 0.02241734 21000 5 NaN
#> random
-#> 1 0.48178933
-#> 2 0.07240574
-#> 3 0.84417056
-#> 4 0.36895498
-#> 5 0.52077080
-#> 6 0.92886854
-#> 7 0.95700741
-#> 8 0.40343856
-#> 9 0.07811400
-#> 10 0.58235908
sessionInfo()
-#> R version 4.3.1 (2023-06-16)
+#> R version 4.3.2 (2023-10-31)
#> Platform: x86_64-pc-linux-gnu (64-bit)
#> Running under: Ubuntu 22.04.3 LTS
#>
@@ -857,66 +857,66 @@ Session info#> [8] base
#>
#> other attached packages:
-#> [1] HiCExperiment_1.1.2 HiContactsData_1.3.0 ExperimentHub_2.9.1
-#> [4] AnnotationHub_3.9.2 BiocFileCache_2.9.1 dbplyr_2.3.4
-#> [7] GenomicRanges_1.53.1 GenomeInfoDb_1.37.6 IRanges_2.35.2
-#> [10] S4Vectors_0.39.2 BiocGenerics_0.47.0 dplyr_1.1.3
-#> [13] BiocStyle_2.29.2
+#> [1] HiCExperiment_1.3.0 HiContactsData_1.4.0 ExperimentHub_2.10.0
+#> [4] AnnotationHub_3.10.0 BiocFileCache_2.10.1 dbplyr_2.4.0
+#> [7] GenomicRanges_1.54.1 GenomeInfoDb_1.38.5 IRanges_2.36.0
+#> [10] S4Vectors_0.40.2 BiocGenerics_0.48.1 dplyr_1.1.4
+#> [13] BiocStyle_2.30.0
#>
#> loaded via a namespace (and not attached):
-#> [1] DBI_1.1.3 bitops_1.0-7
-#> [3] rlang_1.1.1 magrittr_2.0.3
-#> [5] matrixStats_1.0.0 compiler_4.3.1
-#> [7] RSQLite_2.3.1 png_0.1-8
-#> [9] systemfonts_1.0.4 vctrs_0.6.3
-#> [11] stringr_1.5.0 pkgconfig_2.0.3
+#> [1] DBI_1.2.0 bitops_1.0-7
+#> [3] rlang_1.1.2 magrittr_2.0.3
+#> [5] matrixStats_1.2.0 compiler_4.3.2
+#> [7] RSQLite_2.3.4 png_0.1-8
+#> [9] systemfonts_1.0.5 vctrs_0.6.5
+#> [11] stringr_1.5.1 pkgconfig_2.0.3
#> [13] crayon_1.5.2 fastmap_1.1.1
-#> [15] XVector_0.41.1 ellipsis_0.3.2
-#> [17] utf8_1.2.3 promises_1.2.1
+#> [15] XVector_0.42.0 ellipsis_0.3.2
+#> [17] utf8_1.2.4 promises_1.2.1
#> [19] rmarkdown_2.25 tzdb_0.4.0
#> [21] ggbeeswarm_0.7.2 strawr_0.0.91
-#> [23] ragg_1.2.5 purrr_1.0.2
-#> [25] bit_4.0.5 xfun_0.40
-#> [27] zlibbioc_1.47.0 cachem_1.0.8
-#> [29] jsonlite_1.8.7 blob_1.2.4
-#> [31] later_1.3.1 rhdf5filters_1.13.5
-#> [33] DelayedArray_0.27.10 Rhdf5lib_1.23.2
-#> [35] BiocParallel_1.35.4 interactiveDisplayBase_1.39.0
-#> [37] parallel_4.3.1 R6_2.5.1
-#> [39] bslib_0.5.1 stringi_1.7.12
-#> [41] jquerylib_0.1.4 Rcpp_1.0.11
-#> [43] bookdown_0.35 SummarizedExperiment_1.31.1
-#> [45] knitr_1.44 readr_2.1.4
-#> [47] httpuv_1.6.11 Matrix_1.6-1.1
-#> [49] tidyselect_1.2.0 abind_1.4-5
-#> [51] yaml_2.3.7 codetools_0.2-19
-#> [53] curl_5.1.0 lattice_0.21-8
-#> [55] tibble_3.2.1 withr_2.5.1
-#> [57] InteractionSet_1.29.1 Biobase_2.61.0
-#> [59] shiny_1.7.5 KEGGREST_1.41.4
-#> [61] ggrastr_1.0.2 evaluate_0.22
-#> [63] desc_1.4.2 Biostrings_2.69.2
-#> [65] pillar_1.9.0 BiocManager_1.30.22
-#> [67] filelock_1.0.2 MatrixGenerics_1.13.1
-#> [69] generics_0.1.3 vroom_1.6.4
-#> [71] rprojroot_2.0.3 RCurl_1.98-1.12
-#> [73] hms_1.1.3 ggplot2_3.4.3
-#> [75] BiocVersion_3.18.0 munsell_0.5.0
-#> [77] scales_1.2.1 xtable_1.8-4
-#> [79] glue_1.6.2 tools_4.3.1
-#> [81] BiocIO_1.11.0 RSpectra_0.16-1
-#> [83] fs_1.6.3 rhdf5_2.45.1
-#> [85] grid_4.3.1 tidyr_1.3.0
-#> [87] colorspace_2.1-0 AnnotationDbi_1.63.2
-#> [89] GenomeInfoDbData_1.2.10 beeswarm_0.4.0
-#> [91] vipor_0.4.5 cli_3.6.1
-#> [93] rappdirs_0.3.3 textshaping_0.3.6
-#> [95] fansi_1.0.4 S4Arrays_1.1.6
-#> [97] gtable_0.3.4 HiContacts_1.3.2
-#> [99] sass_0.4.7 digest_0.6.33
-#> [101] SparseArray_1.1.12 memoise_2.0.1
-#> [103] htmltools_0.5.6 pkgdown_2.0.7
-#> [105] lifecycle_1.0.3 httr_1.4.7
+#> [23] ragg_1.2.7 purrr_1.0.2
+#> [25] bit_4.0.5 xfun_0.41
+#> [27] zlibbioc_1.48.0 cachem_1.0.8
+#> [29] jsonlite_1.8.8 blob_1.2.4
+#> [31] highr_0.10 later_1.3.2
+#> [33] rhdf5filters_1.14.1 DelayedArray_0.28.0
+#> [35] Rhdf5lib_1.24.1 BiocParallel_1.36.0
+#> [37] interactiveDisplayBase_1.40.0 parallel_4.3.2
+#> [39] R6_2.5.1 bslib_0.6.1
+#> [41] stringi_1.8.3 jquerylib_0.1.4
+#> [43] Rcpp_1.0.11 bookdown_0.37
+#> [45] SummarizedExperiment_1.32.0 knitr_1.45
+#> [47] readr_2.1.4 httpuv_1.6.13
+#> [49] Matrix_1.6-1.1 tidyselect_1.2.0
+#> [51] abind_1.4-5 yaml_2.3.8
+#> [53] codetools_0.2-19 curl_5.2.0
+#> [55] lattice_0.22-5 tibble_3.2.1
+#> [57] InteractionSet_1.30.0 Biobase_2.62.0
+#> [59] shiny_1.8.0 withr_2.5.2
+#> [61] KEGGREST_1.42.0 ggrastr_1.0.2
+#> [63] evaluate_0.23 desc_1.4.3
+#> [65] Biostrings_2.70.1 pillar_1.9.0
+#> [67] BiocManager_1.30.22 filelock_1.0.3
+#> [69] MatrixGenerics_1.14.0 generics_0.1.3
+#> [71] vroom_1.6.5 RCurl_1.98-1.13
+#> [73] hms_1.1.3 ggplot2_3.4.4
+#> [75] BiocVersion_3.18.1 munsell_0.5.0
+#> [77] scales_1.3.0 xtable_1.8-4
+#> [79] glue_1.6.2 tools_4.3.2
+#> [81] BiocIO_1.12.0 RSpectra_0.16-1
+#> [83] fs_1.6.3 rhdf5_2.46.1
+#> [85] grid_4.3.2 tidyr_1.3.0
+#> [87] colorspace_2.1-0 AnnotationDbi_1.64.1
+#> [89] GenomeInfoDbData_1.2.11 beeswarm_0.4.0
+#> [91] vipor_0.4.7 cli_3.6.2
+#> [93] rappdirs_0.3.3 textshaping_0.3.7
+#> [95] fansi_1.0.6 S4Arrays_1.2.0
+#> [97] gtable_0.3.4 HiContacts_1.4.0
+#> [99] sass_0.4.8 digest_0.6.33
+#> [101] SparseArray_1.2.3 memoise_2.0.1
+#> [103] htmltools_0.5.7 pkgdown_2.0.7
+#> [105] lifecycle_1.0.4 httr_1.4.7
#> [107] mime_0.12 bit64_4.0.5