I have two different feature sets (so, with same number of rows and the labels are the same), in my case DataFrames:
df1:
| A | B | C |
-------------
| 1 | 4 | 2 |
| 1 | 4 | 8 |
| 2 | 1 | 1 |
| 2 | 3 | 0 |
| 3 | 2 | 5 |
df2:
| E | F |
---------
| 6 | 1 |
| 1 | 3 |
| 8 | 1 |
| 2 | 8 |
| 5 | 2 |
labels:
| labels |
----------
| 5 |
| 5 |
| 1 |
| 7 |
| 3 |
I want to use them to train a VotingClassifier. But the fitting step only allows to specify a single feature set. Goal is to fit clf1 with df1 and clf2 with df2.
eclf = VotingClassifier(estimators=[('df1-clf', clf1), ('df2-clf', clf2)], voting='soft')
eclf.fit(...)
How should I proceed with this kind of situation? Is there any easy solution?