code: function () {
              var axis = this,
                chart = axis.chart,
                key = axis._maxTicksKey,
                tickPositions = axis.tickPositions,
                maxTicks = chart.maxTicks;
  
              if (maxTicks && maxTicks[key] && !axis.isDatetimeAxis && !axis.categories && !axis.isLinked &&
                axis.options.alignTicks !== false && this.min !== UNDEFINED) {
                  var oldTickAmount = axis.tickAmount,
                    calculatedTickAmount = tickPositions.length,
                    tickAmount;
  
                  // set the axis-level tickAmount to use below
                  axis.tickAmount = tickAmount = maxTicks[key];
  
                  if (calculatedTickAmount < tickAmount) {
                      while (tickPositions.length < tickAmount) {
                          tickPositions.push(correctFloat(
                            tickPositions[tickPositions.length - 1] + axis.tickInterval
                          ));
                      }
                      axis.transA *= (calculatedTickAmount - 1) / (tickAmount - 1);
                      axis.max = tickPositions[tickPositions.length - 1];
  
                  }
                  if (defined(oldTickAmount) && tickAmount !== oldTickAmount) {
                      axis.isDirty = true;
                  }
              }
          }
docs: When using multiple axes, adjust the number of ticks to match the highest
  number of ticks in that group