CreateCenteredBED-methods {R3CPET} | R Documentation

## Create centered interactions

### Description

This helper method can be used to create a "bed" file in which the coordinates of the regions are the centre of the interactions in the raw data. in R3CPET we suppose that the centre of the interactions are the most enriched when doing read mapping ,thus, we consider just the region around the centre to detect the TFBS.

### Usage

    ## S4 method for signature 'character'
    CreateCenteredBED(file, header=TRUE,dist=1000)

### Arguments

`file` | a `character` indicating the location of the rawdata file. the file should be a six column "bed" file in which the fist 3 columns indicate the left side interaction (chr, start, stop) and the other 3 columns indicate the right side interaction.
`header` | `logical`, indicates if the first line in the file is a header.
`dist` | `numeric`, indicated the distance around the center of the region to take.

### Value

A 4 columns `data.frame` object, in which the first 3 columns indicate the location of the region and the 4th on indicate its name. The names are of the format `PET#\w+.1` for the left side regions and `PET#\w+.2` for the right side ones.

### Author(s)

Mohamed Nadhir Djekidel (nde12@mails.tsinghua.edu.cn)

### References

Mohamed Nadhir D, Yang C et al 3CPET: Finding Co-factor Complexes in Chia-PET experiment using a Hierarchical Dirichlet Process, ....

### See Also

`ChiapetExperimentData`, `loadTFBS` , `loadPETs`, `loadPPI`, `createIndexes`.

### Examples

    ## get interactions file location
    petFile <- file.path(system.file("example",package="R3CPET"),"HepG2_interactions.txt")

    res <- CreateCenteredBED(petFile, header=TRUE, dist=1000)
    head(res)

[Package R3CPET version 1.24.0 Index]