relativeRingSizes (relativeRingSizesFunction) {
        function assertPortionsArray (relativeSizes, numberOfRings) {
            if (!Array.isArray(relativeSizes)) {
                throw new BadArgumentException('relativeRingSizes function must return an array');
            }

            const portionsSum = sum(relativeSizes);
            if (Math.abs(portionsSum - 1) > constants.NEGLIGIBLE_NUMBER) {
                throw new BadArgumentException(
                    `relativeRingSizes : portions must add up to 1, but sum was ${portionsSum}`);
            }

            if (relativeSizes.length !== numberOfRings) {
                throw new BadArgumentException(
                    `relativeRingSizes : number of values must match number of rings (${
                        numberOfRings}) but was ${relativeSizes.length}`);
            }
        }
        return {
            partitionDy: () => 1,
            scaleInnerRadius: d => this._scaleRadius(d.data.path.length - 1, d.y0),
            scaleOuterRadius: d => this._scaleRadius(d.data.path.length, d.y1),
            relativeRingSizesFunction: ringCount => {
                const result = relativeRingSizesFunction(ringCount);
                assertPortionsArray(result, ringCount);
                return result;
            }
        };
    }
Constructs a RingSizes parameter for {@link SunburstChart#ringSizes ringSizes()} using the given function
to determine each rings width.

* The function must return an array containing portion values for each ring/level of the chart.
* The length of the array must match the number of rings of the chart at runtime, which is provided as the only
  argument.
* The sum of all portions from the array must be 1 (100%).

@example
// specific relative portions (the number of rings (3) is known in this case)
chart.ringSizes(chart.relativeRingSizes(function (ringCount) {
    return [.1, .3, .6];
});
@param {Function} [relativeRingSizesFunction]
@returns {RingSizes}