title: pandas DataFrame set value on boolean mask
body: <p>I'm trying to set a number of different in a pandas DataFrame all to the same value. I thought I understood boolean indexing for pandas, but I haven't found any resources on this specific error.</p>
  
  <pre><code>import pandas as pd 
  df = pd.DataFrame({'A': [1, 2, 3], 'B': ['a', 'b', 'f']})
  mask = df.isin([1, 3, 12, 'a'])
  df[mask] = 30
  Traceback (most recent call last):
  ...
  TypeError: Cannot do inplace boolean setting on mixed-types with a non np.nan value
  </code></pre>
  
  <p>Above, I want to replace all of the <code>True</code> entries in the mask with the value <code>30</code>.</p>
  
  <p>I could do <code>df.replace</code> instead, but masking feels a bit more efficient and intuitive here. Can someone explain the error, and provide an efficient way to set all of the values?</p>