@@ -21,16 +21,16 @@ var BADNUM = require('../../constants/numerical').BADNUM;
21
21
* @param {Array } traces
22
22
* Array of calculated traces
23
23
* @param {object } opts
24
- * - @param {boolean} [separateNegativeValues ]
24
+ * - @param {boolean} [sepNegVal ]
25
25
* If true, then split data at the same position into a bar
26
26
* for positive values and another for negative values
27
- * - @param {boolean} [dontMergeOverlappingData ]
27
+ * - @param {boolean} [overlapNoMerge ]
28
28
* If true, then don't merge overlapping bars into a single bar
29
29
*/
30
30
function Sieve ( traces , opts ) {
31
31
this . traces = traces ;
32
- this . separateNegativeValues = opts . separateNegativeValues ;
33
- this . dontMergeOverlappingData = opts . dontMergeOverlappingData ;
32
+ this . sepNegVal = opts . sepNegVal ;
33
+ this . overlapNoMerge = opts . overlapNoMerge ;
34
34
35
35
// for single-bin histograms - see histogram/calc
36
36
var width1 = Infinity ;
@@ -81,7 +81,7 @@ Sieve.prototype.put = function put(position, value) {
81
81
* @method
82
82
* @param {number } position Position of datum
83
83
* @param {number } [value] Value of datum
84
- * (required if this.separateNegativeValues is true)
84
+ * (required if this.sepNegVal is true)
85
85
* @returns {number } Current bin value
86
86
*/
87
87
Sieve . prototype . get = function put ( position , value ) {
@@ -95,14 +95,14 @@ Sieve.prototype.get = function put(position, value) {
95
95
* @method
96
96
* @param {number } position Position of datum
97
97
* @param {number } [value] Value of datum
98
- * (required if this.separateNegativeValues is true)
98
+ * (required if this.sepNegVal is true)
99
99
* @returns {string } Bin label
100
- * (prefixed with a 'v' if value is negative and this.separateNegativeValues is
100
+ * (prefixed with a 'v' if value is negative and this.sepNegVal is
101
101
* true; otherwise prefixed with '^')
102
102
*/
103
103
Sieve . prototype . getLabel = function getLabel ( position , value ) {
104
- var prefix = ( value < 0 && this . separateNegativeValues ) ? 'v' : '^' ;
105
- var label = ( this . dontMergeOverlappingData ) ?
104
+ var prefix = ( value < 0 && this . sepNegVal ) ? 'v' : '^' ;
105
+ var label = ( this . overlapNoMerge ) ?
106
106
position :
107
107
Math . round ( position / this . binWidth ) ;
108
108
return prefix + label ;
0 commit comments