extractDomains: A domains file can contains lines of many different genomes....

Description Usage Arguments Value Examples

View source: R/extractGenome.R

Description

A domains file can contains lines of many different genomes. This function extract the domains of a specific genome

Usage

1
extractDomains(domains, genome, reverse = FALSE)

Arguments

domains

The domains in data.frame

genome

The genome ID of the genome, whose domains need to be extracted

reverse

if reverse = TRUE then the function will not extract the lines of the genome but remove it

Value

the domains of the interested genome in data.frame

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
## Create a pseudo domains table
V1 <- c(
    "1001705at2759#1001705at2759|HUMAN@9606@3|Q15291|1",
    "551907at2759#551907at2759|AMPQU@400682@2|400682_0:001490|1"
)
V2 <- c(
    "1001705at2759|HOMSA@9606@2|9606_0:00004c",
    "551907at2759|AMPQU@400682@2|400682_0:001490|1"
)
V3 <- c(538, 1087)
V4 <- c("pfam_WD40", "flps_SINGLE_{G}")
V5 <- c(17, 1030)
V6 <- c(52, 1058)
V7 <- c(0.2265, 0.0936)
V8 <- c("Y", "Y")
domains <- data.frame(V1, V2, V3, V4, V5, V6, V7, V8)
## extract domains table of HUMAN@9606@3
newDomains <- extractDomains(domains, "HUMAN@9606@3")
print.data.frame(newDomains)

giangnguyen0709/fCAT documentation built on Feb. 10, 2021, 4:31 a.m.