Function Repository Resource:

# ScaledRankChart

Display a chart of scaled counts of elements in a list

Contributed by: Michael Sollami
 ResourceFunction["ScaledRankChart"][list] displays a chart of ranked counts of elements in a given list.

## Details and Options

ResourceFunction["ScaledRankChart"] uses several methods to make it easier to understand commonly occuring elements by charting elements to occupy space in proportion to the log of their frequency. ResourceFunction["ScaledRankChart"] groups together remaining frequencies of elements after a certain threshold number has been passed.
ResourceFunction["ScaledRankChart"] relies on the resource functions Equisample and MapColumn
ResourceFunction["ScaledRankChart"] takes the the following options:
 ImageSize Automatic how big the chart should be LabelStyle None style to apply to label texts "Logarithmic" True whether chart area is a linear or logarithmic function of frequency LogPower 1/2 power p to use in pie-chart area formula: Log[1+count]*countp MaxItems 40 max number of items beyond which they are lumped in the category “other” "MinCount" None minimum count, beyond which they are lumped in category “other” "NumberExamples" 10 number of examples to use in 2-argument form "OtherChart" False whether to allow mousing-over the “other” category to see next section of distribution "Rotation" Automatic how much to rotate the starting sector axis "ShowCounts" True whether to show counts next to each chart element "Tooltips" None rules mapping elements to tooltips "Type" PieChart the type of chart displayed (BarChart or PieChart) "UseLegend" False whether to show a separate legend box

## Examples

### Basic Examples (3)

Show a chart of the distribution of random variables:

 In[1]:=
 In[2]:=
 Out[2]=
 In[3]:=
 Out[3]=

Rapidly-dwindling distributions are still legible:

 In[4]:=
 Out[5]=
 In[6]:=
 Out[6]=

Chart the ranked distribution of random variables:

 In[7]:=
 Out[7]=

### Applications (2)

Tokenize the text of Alice in Wonderland:

 In[8]:=
 Out[9]=

Display the distribution of words in the text, grouping elements making up less than 1% under the category “other”:

 In[10]:=
 Out[10]=

Michael Sollami

## Version History

• 1.0.0 – 31 March 2020