nanops._ensure_numeric is used to make sure ndarrays are a numeric dtype. However, it can't handle the case where the dtype is object and one or more of the axes is complex:
>>> from pandas.core.nanops import nanmean
>>> import numpy as np
>>>
>>> value = np.vstack([np.array(np.nan).astype('O'), np.array(1+1j).astype('O')])
>>> nanmean(value, axis=0)
TypeError: can't convert complex to float