Learn R Programming

CNEr (version 1.8.3)

chainPreNet: chainPreNet

Description

Wrapper function of chainPreNet: Remove chains that don't have a chance of being netted. This function doesn't work on Windows platform since Kent utilities only support Linux and Unix platform.

Usage

chainPreNet(allChain, assemblyTarget, assemblyQuery, allPreChain=paste0(sub("\\.2bit$", "", basename(assemblyTarget), ignore.case = TRUE), ".", sub("\\.2bit$", "", basename(assemblyQuery), ignore.case = TRUE), ".all.pre.chain"), removeAllChain=TRUE, binary="chainPreNet")

Arguments

allChain
character(1): file names of input allChain file.
assemblyTarget
character(1): the file name of target assembly twoBit file.
assemblyQuery
character(1): the file name of query assembly twoBit file.
allPreChain
character(1): file names of merged allPreChain file.
removeAllChain
boolean: When TRUE, the input allChain file will be removed after the conversion.
binary
character(1): the name/filename of the binary chainPreNet to call.

Value

character(1): the file names of merged allPreChain file.

References

http://hgdownload.cse.ucsc.edu/admin/exe/

See Also

chainMergeSort

Examples

Run this code
  ## Not run: 
#   ## This example doesn't run because it requires two bit files and external
#   ## Kent utilities.
#     allChain <- file.path("/Users/gtan/OneDrive/Project/CSC/CNEr/axt",
#                           "danRer10.hg38.all.chain")
#     assemblyTarget <- "/Users/gtan/OneDrive/Project/CSC/CNEr/2bit/danRer10.2bit"
#     assemblyQuery <- "/Users/gtan/OneDrive/Project/CSC/CNEr/2bit/hg38.2bit"
#     chainPreNet(allChain, assemblyTarget, assemblyQuery,
#                 allPreChain=file.path(
#                               "/Users/gtan/OneDrive/Project/CSC/CNEr/axt",
#                                       paste0(sub("\\.2bit$", "", 
#                                                  basename(assemblyTarget),
#                                                  ignore.case = TRUE), ".", 
#                                              sub("\\.2bit$", "",
#                                                  basename(assemblyQuery),
#                                                  ignore.case = TRUE),
#                                                  ".all.pre.chain")),
#                 removeAllChain=FALSE, binary="chainPreNet")
#   ## End(Not run)

Run the code above in your browser using DataLab