Package org.snpeff.stats
Class CountByType
java.lang.Object
org.snpeff.stats.CountByType
- All Implemented Interfaces:
Serializable
Counters indexed by 'type' (type is a generic string that can mean anything)
- Author:
- pcingola
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlong
Add score for a typeboolean
long
How many counts of this type?getColorHtml
(String type) Background color used for table (heatmap)long
Count for this typedouble
Score for this typelong
List all types (alphabetically sorted) We need it as a getter for summary page (freemarker)boolean
boolean
hasData()
boolean
long
long
Increment counter for a given typeboolean
isEmpty()
Is this emptykeySet()
keysRanked
(boolean reverse) List all types (sorted by count)List all types (alphabetically sorted)long
max()
Maximum countlong
min()
Minimum countdouble
Percentage by typeranks
(boolean reverse) A map: key -> rank(counts)void
Remove this entry typevoid
long
sum()
Sum all counts.toString()
toString
(boolean showScores) toStringTop
(int n)
-
Field Details
-
TOTAL_TYPE
- See Also:
-
-
Constructor Details
-
CountByType
public CountByType()
-
-
Method Details
-
addScore
Add score for a type -
contains
-
get
How many counts of this type? -
getColorHtml
Background color used for table (heatmap)- Returns:
- An html coded color
-
getCount
Count for this type -
getScore
Score for this type -
getTotalCount
public long getTotalCount() -
getTypeList
List all types (alphabetically sorted) We need it as a getter for summary page (freemarker) -
hasCount
-
hasData
public boolean hasData() -
hasScore
-
inc
-
inc
Increment counter for a given type -
isEmpty
public boolean isEmpty()Is this empty -
keySet
-
keysRanked
List all types (sorted by count) -
keysSorted
List all types (alphabetically sorted) -
max
public long max()Maximum count -
min
public long min()Minimum count -
percent
Percentage by type -
ranks
A map: key -> rank(counts) -
remove
Remove this entry type -
setScore
-
sum
public long sum()Sum all counts. -
toString
-
toString
-
toString
-
toStringLine
-
toStringSort
-
toStringTop
-