Skip to content

Commit

Permalink
fix: remove hicrep dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
js2264 committed Nov 7, 2023
1 parent 82d08cc commit 9b3fa58
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 73 deletions.
10 changes: 0 additions & 10 deletions .github/workflows/rworkflows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,6 @@ jobs:
r: auto
cont: ghcr.io/bioconductor/bioconductor:devel
rspm: https://packagemanager.rstudio.com/cran/__linux__/focal/release
# - os: macOS-latest
# bioc: release
# r: auto
# cont: ~
# rspm: ~
# - os: windows-latest
# bioc: release
# r: auto
# cont: ~
# rspm: ~
steps:
- uses: neurogenomics/rworkflows@master
with:
Expand Down
3 changes: 0 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ Imports:
WGCNA,
diffHic,
strawr,
hicrep,
multiHiCcompare,
TopDom,
GOTHiC,
Expand All @@ -41,8 +40,6 @@ Imports:
quarto,
sessioninfo
Suggests:
Remotes:
github::TaoYang-dev/hicrep
biocViews:
HiC,
DNA3DStructure
Expand Down
1 change: 1 addition & 0 deletions inst/index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ aforementioned packages pre-installed, and initiate an interactive R session.

The OHCA book has been rendered in R thanks to a number of packages, including but not only:

- **`BiocBook`**
- `devtools`
- `quarto`
- `rebook`
Expand Down
60 changes: 2 additions & 58 deletions inst/pages/interoperability.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ This notebook illustrates how to use a range of popular Hi-C—related `R` packa
following packages is illustrated here:

- `diffHic`
- `hicrep`
<!-- - `hicrep` -->
- `multiHiCcompare`
- `TopDom`
- `GOTHiC`
Expand All @@ -29,7 +29,7 @@ library(InteractionSet)
library(HiCExperiment)
library(HiContactsData)
library(plyinteractions)
library(hicrep)
# library(hicrep)
library(multiHiCcompare)
library(dplyr)
library(tidyr)
Expand Down Expand Up @@ -128,62 +128,6 @@ p + geom_rect(
)
```

## HiCrep

`hicrep` is a popular package to compute **stratum-adjusted correlations** between Hi-C datasets (@Yang_2017).
"Stratum" refers to the distance from the main diagonal: with increase distance from the main diagonal,
interactions of the DNA polymer are bound to decrease. `hicrep` computes a "per-stratum" correlation score and
computes a weighted average correlation for entire chromosomes.

::: {.callout-tip}

### Installing `hicrep`

`hicrep` package has been available from Bioconductor for many years but has
been withdrawn from their repositories at some point. You can always install
`hicrep` directly from its GitHub repository as follows:

```{r}
#| eval: false
remotes::install_github('TaoYang-dev/hicrep')
```

:::

In order to use `hicrep`, we first need to create two `HiCExperiment` objects.

```{r eval = FALSE}
# ---- This downloads example `.mcool` files and caches them locally
coolf_eco1 <- HiContactsData('yeast_eco1', 'mcool')
```

```{r}
hic_wt <- import(coolf_wt, format = 'cool')
hic_eco1 <- import(coolf_eco1, format = 'cool')
```

We can now run the main `get.scc` function from `hicrep`. The documentation
for this function is available from the console by typing `?hicrep::get.scc`.
More information is also available from the [GitHub page](https://github.com/TaoYang-dev/hicrep#compute-reproducibility-score-using-hicrep). It informs the end user that
the input for this function should be two intra-chromosomal Hi-C **raw count** matrices
in square (optionally sparse) format.

```{r}
hic_wt
as.matrix(hic_wt["IV"], use.scores = 'count')[1:10, 1:10]
library(hicrep)
scc <- get.scc(
as.matrix(hic_wt["IV"], use.scores = 'count'),
as.matrix(hic_eco1["IV"], use.scores = 'count'),
resol = 1000, h = 25, lbr = 5000, ubr = 50000
)
scc
scc$scc
```

## multiHiCcompare

The `multiHiCcompare` package provides functions for joint
Expand Down
1 change: 0 additions & 1 deletion inst/pages/workflow-centros.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ library(GenomicRanges)
library(InteractionSet)
library(HiCExperiment)
library(HiContactsData)
library(hicrep)
library(multiHiCcompare)
```

Expand Down
1 change: 0 additions & 1 deletion inst/pages/workflow-yeast.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ library(GenomicRanges)
library(InteractionSet)
library(HiCExperiment)
library(HiContactsData)
library(hicrep)
library(multiHiCcompare)
```

Expand Down

0 comments on commit 9b3fa58

Please sign in to comment.