File: AllGenerics.R

package info (click to toggle)
r-bioc-rsamtools 2.22.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 4,488 kB
  • sloc: ansic: 4,904; cpp: 1,586; sh: 40; makefile: 2
file content (199 lines) | stat: -rw-r--r-- 6,050 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
setGeneric("ScanBamParam",
           function(flag=scanBamFlag(), simpleCigar=FALSE,
                    reverseComplement=FALSE, tag=character(0),
                    tagFilter=list(), what=character(0), which,
                    mapqFilter=NA_integer_)
           standardGeneric("ScanBamParam"),
           signature="which")

setGeneric("scanBam",
           function(file, index=file, ...,
                    param=ScanBamParam(what=scanBamWhat()))
           standardGeneric("scanBam"),
           signature="file")

setGeneric("scanBamHeader",
           function(files, ...) standardGeneric("scanBamHeader"))

setGeneric("countBam",
           function(file, index=file, ..., param=ScanBamParam())
           standardGeneric("countBam"),
           signature="file")
 
setGeneric("idxstatsBam",
           function(file, index=file, ...) standardGeneric("idxstatsBam"),
           signature="file")

setGeneric("asBam",
           function(file, destination = sub("\\.sam(\\.gz)?", "", file), ...)
           standardGeneric("asBam"))

setGeneric("asSam",
           function(file, destination = sub("\\.bam", "", file), ...)
           standardGeneric("asSam"))

setGeneric("sortBam",
           function(file, destination, ...)
           standardGeneric("sortBam"))

setGeneric("mergeBam",
           function(files, destination, ...)
           standardGeneric("mergeBam"),
           signature="files")

setGeneric("indexBam",
           function(files, ...) standardGeneric("indexBam"))

setGeneric("filterBam",
           function(file, destination, index=file, ...)
           standardGeneric("filterBam"))

setGeneric("quickBamFlagSummary",
           function(file, ..., param=ScanBamParam(), main.groups.only=FALSE)
           standardGeneric("quickBamFlagSummary"),
           signature="file")

setGeneric("indexFa",
           function(file, ...) standardGeneric("indexFa"))

setGeneric("scanFaIndex",
           function(file, ...) standardGeneric("scanFaIndex"))

setGeneric("countFa",
           function(file, ...) standardGeneric("countFa"))

setGeneric("scanFa",
           function(file, param, ...,
                    as=c("DNAStringSet", "RNAStringSet", "AAStringSet"))
           standardGeneric("scanFa"),
           signature=c("file", "param"))

setGeneric("readPileup",
           function(file, ...) standardGeneric("readPileup"))

## bcf

setGeneric("ScanBcfParam",
           function(fixed=character(), info=character(), geno=character(), 
                    samples=character(), trimEmpty=TRUE, which, ...)
           standardGeneric("ScanBcfParam"),
           signature="which")

setGeneric("isOpen")

setGeneric("isIncomplete")

setGeneric("scanBcfHeader",
           function(file, ...) standardGeneric("scanBcfHeader"))

setGeneric("scanBcf",
           function(file, ...) standardGeneric("scanBcf"))

setGeneric("asBcf",
           function(file, dictionary, destination, ...,
                    overwrite=FALSE, indexDestination=TRUE)
           standardGeneric("asBcf"),
           signature="file")

setGeneric("indexBcf",
           function(file, ...) standardGeneric("indexBcf"))


## other

setGeneric("BamViews",
           function(bamPaths=character(0),
                    bamIndicies=bamPaths,
                    bamSamples=DataFrame(row.names=
                      make.unique(basename(bamPaths))),
                    bamRanges,
                    bamExperiment=list(), ...)
           standardGeneric("BamViews"),
           signature="bamRanges")

## tabix

setGeneric("seqnamesTabix", function(file, ...)
           standardGeneric("seqnamesTabix"))

setGeneric("headerTabix", function(file, ...)
           standardGeneric("headerTabix"))

setGeneric("scanTabix", function(file, ..., param)
           standardGeneric("scanTabix"))

setGeneric("yieldTabix", function(file, ..., yieldSize=1000000L)
           standardGeneric("yieldTabix"),
           signature="file")

## pileup

setGeneric("pileup",
    function(file, index=file, ..., scanBamParam=ScanBamParam(),
             pileupParam=PileupParam())
        standardGeneric("pileup"),
    signature=signature("file"))

setGeneric(".asRegions", function(x) standardGeneric(".asRegions"))

setGeneric("applyPileups",
           function(files, FUN, ..., param)
           {
               .Deprecated("pileup")
               standardGeneric("applyPileups")
           },
           signature=c("files", "param"))

## RsamtoolsFile(s)

setGeneric("index",
           function(object, ..., asNA=TRUE)
           standardGeneric("index"),
           signature="object")

setGeneric("index<-",
           function(object, ..., value) standardGeneric("index<-"))

setGeneric("gzindex",
           function(object, asNA=TRUE)
           standardGeneric("gzindex"),
           signature="object")

setGeneric("gzindex<-",
           function(object, value) standardGeneric("gzindex<-"))

setGeneric("yieldSize",
           function(object, ...) standardGeneric("yieldSize"))

setGeneric("yieldSize<-",
           function(object, ..., value) standardGeneric("yieldSize<-"))

setGeneric("obeyQname",
           function(object, ...) standardGeneric("obeyQname"))

setGeneric("obeyQname<-",
           function(object, ..., value) standardGeneric("obeyQname<-"))

setGeneric("asMates",
           function(object, ...) standardGeneric("asMates"))

setGeneric("asMates<-",
           function(object, ..., value) standardGeneric("asMates<-"))

setGeneric("qnamePrefixEnd",
           function(object, ...) standardGeneric("qnamePrefixEnd"))

setGeneric("qnamePrefixEnd<-",
           function(object, ..., value) standardGeneric("qnamePrefixEnd<-"))

setGeneric("qnameSuffixStart",
           function(object, ...) standardGeneric("qnameSuffixStart"))

setGeneric("qnameSuffixStart<-",
           function(object, ..., value) standardGeneric("qnameSuffixStart<-"))

setGeneric("isOpen")

setGeneric("testPairedEndBam", function(file, index=file, ...) 
           standardGeneric("testPairedEndBam"),
           signature="file")