来自 Highcharts 的词云 - 创建一个放置策略,使单词从最高权重到最低权重排序

Word Cloud from Highcharts - Create a placement strategy so words are ordered from highest weight to lowest

我正在尝试为 Highcharts 中的词云创建一个放置策略,以便词本身根据它们的权重从高到低放置。我不完全确定如何根据他们的文档创建此放置策略。任何帮助都会很棒!

我有这个没有旋转的 jfiddle:https://jsfiddle.net/3gp2L1zw/1/

Highcharts.chart('container', {
    accessibility: {
        screenReaderSection: {
            beforeChartFormat: '<h5>{chartTitle}</h5>' +
                '<div>{chartSubtitle}</div>' +
                '<div>{chartLongdesc}</div>' +
                '<div>{viewTableButton}</div>'
        }
    },
    series: [{
        type: 'wordcloud',
        data: data,
        name: 'Occurrences',
        rotation: {
        from: 0,
        to: 0
        }
    }],
    title: {
        text: 'Wordcloud of Lorem Ipsum'
    }
});

根据下面的文档,我创建了一个简化的演示,其中我向 placementStrategy 添加了另一个方法。
文档:https://www.highcharts.com/docs/chart-and-series-types/word-cloud-series#custom-spiralling-algorithm

现场演示: https://jsfiddle.net/BlackLabel/14q9hxvj/