title: best way to visualize counts for very large number of variables with ggplot?
body: <p>Im currently running LASSO models for particular set of data. There are hundreds of variables found in 17 different models and Im interested in seeing how many models a particular variable is found in. I thought the best way to do this in R would be to create a boxplot with the variable names on one axis and the number of times they show up on the other axis. However, due to the number of variables that exist, the graph is not very readable. This is how it currently looks:</p>
  <p><a href="https://i.stack.imgur.com/6lVk2.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6lVk2.png" alt="Number of LASSO Models Variables are Present In" /></a></p>
  <p>This is the code I wrote to create the plot:</p>
  <pre><code>dt1 %&gt;% ggplot(aes(y=reorder(Variable_Name,-desc(n)),x=n)) + geom_bar(stat=&quot;identity&quot;,
                 width=.5,color=&quot;black&quot;,fill=&quot;grey&quot;) +
    scale_x_continuous(name = &quot;Count&quot;,breaks = c(0,1,2,3,4,5)) + ylab(NULL)
  </code></pre>
  <p>So I would assume that a bar plot would not be the best way to present this information. Does anyone have any suggestion on what to use to better visualize the data? Would a Venn diagram work best in this scenario?</p>
  <p>EDIT:</p>
  <p>I used Timon 's suggestion and this is what I came up with. I still face some space issues but its definitely preferable to the previous attempt.
  <a href="https://i.stack.imgur.com/noqhw.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/noqhw.png" alt="enter image description here" /></a></p>