@@ -1042,7 +1042,7 @@ function autoTickRound(ax) {
10421042
10431043 var maxend = Math . max ( Math . abs ( rng [ 0 ] ) , Math . abs ( rng [ 1 ] ) ) ;
10441044 var rangeexp = Math . floor ( Math . log ( maxend ) / Math . LN10 + 0.01 ) ;
1045- if ( Math . abs ( rangeexp ) > 3 || ax . exponentformat === 'eng' ) {
1045+ if ( Math . abs ( rangeexp ) > ax . minexponent ) {
10461046 if ( isSIFormat ( ax . exponentformat ) && ! beyondSI ( rangeexp ) ) {
10471047 ax . _tickexponent = 3 * Math . round ( ( rangeexp - 1 ) / 3 ) ;
10481048 } else ax . _tickexponent = rangeexp ;
@@ -1496,7 +1496,7 @@ function num2frac(num) {
14961496var SIPREFIXES = [ 'f' , 'p' , 'n' , 'μ' , 'm' , '' , 'k' , 'M' , 'G' , 'T' ] ;
14971497
14981498function isSIFormat ( exponentFormat ) {
1499- return exponentFormat === 'SI' || exponentFormat === 'B' || exponentFormat === 'eng' ;
1499+ return exponentFormat === 'SI' || exponentFormat === 'B' ;
15001500}
15011501
15021502// are we beyond the range of common SI prefixes?
@@ -1525,6 +1525,7 @@ function numFormat(v, ax, fmtoverride, hover) {
15251525 // make a dummy axis obj to get the auto rounding and exponent
15261526 var ah = {
15271527 exponentformat : exponentFormat ,
1528+ minexponent : ax . minexponent ,
15281529 dtick : ax . showexponent === 'none' ? ax . dtick :
15291530 ( isNumeric ( v ) ? Math . abs ( v ) || 1 : 1 ) ,
15301531 // if not showing any exponents, don't change the exponent
0 commit comments