Enable `drop='constant'` in OneHotEncoder

### Describe the workflow you want to enable

Currently the `drop` parameter in `OneHotEncoder` objects support `{‘first’, ‘if_binary’, <array-of-features>, None}` as potential choices, with a strong encouragement to use `None` to allow proper use of regularized linear modeling downstream. However, if there exists features that are constant for a data matrix then it would be really great if `OneHotEncoder` took care of dropping that feature entirely during coding. If all columns in the input matrix were constant perhaps an error could be raised during `.fit(...)` when this option was used for object initialization.

I would like to do the following.
```
>>> oh_encoder = OneHotEncoder(
    sparse_output=False,
    drop='constant',
    handle_unknown='ignore')
```

So that this were possible.
```
>>> X
array([['M', 'O', 'M'],
       ['M', 'A', 'N']], dtype='<U1')
>>> oh_encoder.fit_transform(X)
array([[0., 1., 0., 1.],
       [1., 0., 1., 0.]], dtype='float')
>>> oh_encoder.inverse_transform(oh_encoder.transform(X))
array([['M', 'O', 'M'],
       ['M', 'A', 'N']], dtype='<U1')
```

Please note that this is distinct from using `drop='first'` which would definitely remove the constant columns but also the first column for each feature group in the data matrix columns, which would be pretty crazy. Perhaps, instead of `None` this could become the default choice as well, as this encoding perfectly preserves all the information in the input data matrix.

### Describe your proposed solution

It would be great to have `drop='constant'` as an option.

### Describe alternatives you've considered, if relevant

I have considered writing my own `OneHotEncoder`, but it feels redudant and error prone to do so. I have also tried to specify the constant features per column via the `drop=<array>` method, but there are columns for which I set values to `None` (corresponding to the non-constant columns) but the object didn't like that.

### Additional context

None.

COMMENT:
I ended up sub classing `OneHotEncoder` which gets the job done as I intended. Code below.

```python
import numpy as np
from sklearn.preprocessing import OneHotEncoder

class SuperHotEncoder(OneHotEncoder):
    '''A modified OneHotEncoder that detects
    constant features and removes them prior
    to one-hot encoding.'''

    def __init__(
        self,
        categories='auto',
        sparse_output=True,
        dtype=np.float64,
        handle_unknown='ignore'):
        '''Initializer'''
        super().__init__(
            categories=categories,
            sparse_output=sparse_output,
            dtype=dtype,
            handle_unknown=handle_unknown)
        self.cc = None

    def fit(self, X, y=None):
        '''Model fit'''
        self.cc = None
        cc = np.where((X != X[0]).sum(axis=0) == 0)[0]
        if len(cc) > 0:
            self.cc = cc
            X = np.delete(X, cc, axis=1)
        return super().fit(X, y)

    def transform(self, X):
        '''Transform input'''
        cc = self.cc
        if not cc is None:
            X = np.delete(X, self.cc, axis=1)
        return super().transform(X)
```

Since, I've solved the problem, I am open to closing this issue. However, I still do think a similar functionality within either the `OneHotEncoder` natively or with a separate preprocessor with appropriate support for inverse transformation would be appreciated.

Labels: New Feature, Needs Decision