git-svn-id: file:///home/git/hedgehog.fhcrc.org/bioconductor/trunk/madman/Rpacks/seqTools@128656 bc3139a8-67e5-0310-9ffc-ced21a209358
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,113 @@ |
1 |
+ |
|
2 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
3 |
+## ## |
|
4 |
+## Project : seqTools ## |
|
5 |
+## Created : 26.August.2013 ## |
|
6 |
+## Author : W. Kaisers ## |
|
7 |
+## File : allGenerics.r ## |
|
8 |
+## Content : All static variables and (not directly object related ) ## |
|
9 |
+## function declarations ## |
|
10 |
+## ## |
|
11 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
12 |
+ |
|
13 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
14 |
+## Changing Fastqq object structure |
|
15 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
16 |
+setGeneric("mergeFastqq", function(lhs, rhs) standardGeneric("mergeFastqq")) |
|
17 |
+setGeneric("meltDownK", function(object, newK) standardGeneric("meltDownK")) |
|
18 |
+ |
|
19 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
20 |
+## Preparation for Hierarchical clustering (HC) |
|
21 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
22 |
+setGeneric("cbDistMatrix", function(object, nReadNorm = max(nReads(object))) |
|
23 |
+ standardGeneric("cbDistMatrix")) |
|
24 |
+ |
|
25 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
26 |
+## Slot accessors |
|
27 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
28 |
+ |
|
29 |
+setGeneric("fileNames", function(object) standardGeneric("fileNames")) |
|
30 |
+setGeneric("collectTime", function(object) standardGeneric("collectTime")) |
|
31 |
+setGeneric("collectDur", function(object) standardGeneric("collectDur")) |
|
32 |
+setGeneric("getK", function(object) standardGeneric("getK")) |
|
33 |
+setGeneric("nFiles", function(object) standardGeneric("nFiles")) |
|
34 |
+setGeneric("nNnucs", function(object) standardGeneric("nNnucs")) |
|
35 |
+setGeneric("nReads", function(object) standardGeneric("nReads")) |
|
36 |
+setGeneric("maxSeqLen", function(object) standardGeneric("maxSeqLen")) |
|
37 |
+setGeneric("seqLenCount", function(object) standardGeneric("seqLenCount")) |
|
38 |
+setGeneric("nucFreq", function(object, i) standardGeneric("nucFreq")) |
|
39 |
+setGeneric("gcContent", function(object, i) standardGeneric("gcContent")) |
|
40 |
+ |
|
41 |
+setGeneric("gcContentMatrix", function(object) |
|
42 |
+ standardGeneric("gcContentMatrix")) |
|
43 |
+setGeneric("getGCcontent", function(object) standardGeneric("getGCcontent")) |
|
44 |
+ |
|
45 |
+setGeneric("seqLen", function(object) standardGeneric("seqLen")) |
|
46 |
+setGeneric("kmerCount", function(object) standardGeneric("kmerCount")) |
|
47 |
+ |
|
48 |
+setGeneric("probeLabel", function(object, label) |
|
49 |
+ standardGeneric("probeLabel")) |
|
50 |
+ |
|
51 |
+setGeneric("probeLabel<-", function(object, value) |
|
52 |
+ standardGeneric("probeLabel<-")) |
|
53 |
+ |
|
54 |
+setGeneric("phred", function(object, i) standardGeneric("phred")) |
|
55 |
+ |
|
56 |
+ |
|
57 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
58 |
+## Retrieving Phred distribution |
|
59 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
60 |
+ |
|
61 |
+setGeneric("phredQuantiles", function(object, quantiles, i, ...) |
|
62 |
+ standardGeneric("phredQuantiles")) |
|
63 |
+ |
|
64 |
+setGeneric("plotPhredQuant", function(object, i, main, ...) |
|
65 |
+ standardGeneric("plotPhredQuant")) |
|
66 |
+ |
|
67 |
+## Global Phred content functions |
|
68 |
+setGeneric("phredDist", function(object, i) standardGeneric("phredDist")) |
|
69 |
+ |
|
70 |
+setGeneric("plotPhredDist", function(object, i, maxp=45, col, ...) |
|
71 |
+ standardGeneric("plotPhredDist")) |
|
72 |
+ |
|
73 |
+setGeneric("propPhred", function(object, greater=30, less=93) |
|
74 |
+ standardGeneric("propPhred")) |
|
75 |
+ |
|
76 |
+ |
|
77 |
+setGeneric("mergedPhred", function(object) standardGeneric("mergedPhred")) |
|
78 |
+ |
|
79 |
+setGeneric("mergedPhredQuantiles", function(object, quantiles) |
|
80 |
+ standardGeneric("mergedPhredQuantiles")) |
|
81 |
+ |
|
82 |
+setGeneric("plotMergedPhredQuant", function(object, main, ...) |
|
83 |
+ standardGeneric("plotMergedPhredQuant")) |
|
84 |
+ |
|
85 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
86 |
+## Predefined Plot functions |
|
87 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
88 |
+ |
|
89 |
+setGeneric("plotNucFreq", function(object, i, main, maxx, ...) |
|
90 |
+ standardGeneric("plotNucFreq")) |
|
91 |
+ |
|
92 |
+setGeneric("plotGCcontent", function(object,main,...) |
|
93 |
+ standardGeneric("plotGCcontent")) |
|
94 |
+ |
|
95 |
+setGeneric("plotNucCount", function(object, nucs=16, maxx, ...) |
|
96 |
+ standardGeneric("plotNucCount")) |
|
97 |
+ |
|
98 |
+setGeneric("plotKmerCount", |
|
99 |
+ function(object, index, mxey, main="K-mer count", ...) |
|
100 |
+ standardGeneric("plotKmerCount")) |
|
101 |
+ |
|
102 |
+ |
|
103 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
104 |
+## Singular Value decomposition based on k-mer counts |
|
105 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
106 |
+ |
|
107 |
+setGeneric("kmerSvd", function(object) standardGeneric("kmerSvd")) |
|
108 |
+ |
|
109 |
+ |
|
110 |
+ |
|
111 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |
|
112 |
+## END OF FILE |
|
113 |
+## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ## |