I have been working with a manufacturing process. It would be very efficient to build a machine learning model for the kind of data that I have. So, my dataset has typically three inputs.

VAl_1 VAl_2 Val_3
8 1 1
10 2 2
12 3 3
14 4 1

VAL_1 can be from 8 to 12 and it is a continuous variable.
VAL_2 is a number from 1 to 4. (not continuous)
VAL_3 is a number from 1 to 3. (not continuous)

The output is like a function $y = f(x)$, where $x$ is a continuous value in the range $(0,1)$

For example, a sample row of my dataset is as follows:

VAl_1 VAl_2 Val_3 y(0) y(0.2) y(0.4) y(0.6) y(0.8) y(1.0)
8 1 1 0.00025 0.0856 0.8946 0.00524 0.872 0.5242

I want to build a model that predicts y(x) given VAL_1, VAL_2, VAL_3

How to deal with features that are both continuous and not continuous in the same model?

Any ideas or thoughts on how I should proceed with such a dataset would be greatly appreciated.

I did try the following:

Normalized VAL_1. I tried encoding features VAL_2, VAL_3.

Normalized the values of y(x).

Tried to fit linear regression, polynomial regression models. But the value of R_square is around 68%.

Are there any better ways to improve the model?

  • $\begingroup$ Are VAL_2, VAL_3 integers (counts) or categorical? Else, look into functional data analysis, see tag functional-data-analysis $\endgroup$ – kjetil b halvorsen Jun 14 at 21:07
  • $\begingroup$ You can use a gradient boosted model - regression, I think. It can handle both continuous and categorical input. $\endgroup$ – Adrian Keister Jun 15 at 1:06
  • $\begingroup$ VAL_1, VAL_2 are just integers. $\endgroup$ – Siva Teja Jun 15 at 4:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.