judithabk6 / med_bench

BSD 3-Clause "New" or "Revised" License
8 stars 3 forks source link

DataConversionWarning #82

Open houssamzenati opened 6 months ago

houssamzenati commented 6 months ago

Often when launching an estimator we get the following warning message from sklearn:

DataConversionWarning: A column-vector y was passed when a 1d array was expected. Please change the shape of y to (n_samples, ), for example using ravel().

this stems from the classifiers and regressors where the treatment t or or outcome y have shapes (n_samples, 1) instead of (n_samples,).

It would be great to reshape the treatment and outcome variables instead nuisances.py to remove this warning message. Most likely, removing the t.reshape(-1,1) operations should suffice.