3
$\begingroup$

I have data with some factors, say, a list of music albums by different artists which are owned by me. I counted the unique factors to arrive at a list of artist names with an associated count of albums, like this:

name                             count

Johnny Cash                       10
The Beatles                        7
Blur                               6
Gorillaz                           3
The Good, the Bad and the Queen    1
The Rolling Stones                 1
The Doors                          1
The Jimi Hendrix Experience        1
The Ramones                        1
The Clash                          1
The Who                            1
The White Stripes                  1
The Black Keys                     1
The Specials                       1
The Cure                           1
The Band                           1
The The                            1

What's the best way to visualize that a large portion (one third, to be precise) of my music collection consists of albums of singleton artists?

My first idea was to plot the count as x-value and the cumulative sum of the count as y-value in a way that the y-value increases, similar to a Lorenz plot. I am wondering - are there better ways to visualize this large portion of low-frequencies?

I'd appreciate either a general suggestion to plot what against what or corresponding R-code.

$\endgroup$
2
  • $\begingroup$ So to clarify: are you interested in the distribution of artist counts? i.e. the number of artists with one album, the number of artists with two albums, etc. $\endgroup$
    – Zoë Clark
    Commented Jul 3, 2014 at 14:13
  • $\begingroup$ If plotting the distribution of artist counts helps to visualize the difference to a record collection of 13 artists which all have 3 albums, then, yes, this may be what I am looking for. $\endgroup$
    – Roland
    Commented Jul 3, 2014 at 14:55

1 Answer 1

2
$\begingroup$

This sounds like a job for Cleveland's dotplot - which is really just a nice looking horizontal barchart.

Assuming your data frame is called df:

R> ## count the number of artist with each number of counts
R> album_counts = table(df$count)
R> ## rev because I find it looks better to have the larger counts at the top
R> dotchart(rev(album_counts))

Another option is to just use a plain old barchart with the barplot() function.

You also allude to the need to compare record collections. If you want to compare several record collections you might just calculate a diversity index for each collection and directly compare those.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.