measureBoundingSphere = (...geometries) => {
  geometries = flatten(geometries)

  const results = geometries.map((geometry) => {
    if (path2.isA(geometry)) return measureBoundingSphereOfPath2(geometry)
    if (geom2.isA(geometry)) return measureBoundingSphereOfGeom2(geometry)
    if (geom3.isA(geometry)) return measureBoundingSphereOfGeom3(geometry)
    return [[0, 0, 0], 0]
  })
  return results.length === 1 ? results[0] : results
}
Measure the (approximate) bounding sphere of the given geometries.
@see https://en.wikipedia.org/wiki/Bounding_sphere
@param {...Object} geometries - the geometries to measure
@return {Array} the bounding sphere for each geometry, i.e. [centroid, radius]
@alias module:modeling/measurements.measureBoundingSphere

@example
let bounds = measureBoundingSphere(cube())