added support for regression