title: How to calculate the mean of a specific value in columns in Python?
body: <p>I'm trying to drop columns that have too many missing values. How can I count the occurrence of some values within columns since the missing values are represented using 99 or 90</p>
  <p>here is the code that is supposed to drop columns that exceed the threshold value</p>
  <pre><code>threshold = 0.6
  
  data = data[data.columns[[data.column == 90 or data.column == 99].count().mean() &lt; threshold]]
  </code></pre>
  <p>I'm not quite used to using pandas, any suggestions would be helpful</p>