# Which predictive algorithm can be used to predict a number given other numbers?

I am currently searching for a supervised learning algorithm that can be used to predict the output given a large enough training set.

Here's a simple example. Suppose the training dataset is {[A=1, B=330, C=1358.238902], result=234.244378} and the test dataset {[A=893, B=34, C=293], result=?}

My intention is to predict ? using the input values and result given in the training dataset.

What algorithm would be effective for this problem given the wide range of my input/output values? Would this require some sort of regression algorithm?

• 1. You need more training data, ideally 10000+. 2 From my experience xgboost shows good results for such kind of data – Stepan Novikov Aug 15 '17 at 16:56
• @StepanNovikov thank you for the recommendation - I do have a fairly large training set already (roughly 4000+). I will also check-out xgboost. Thanks – Cryptonaut Aug 15 '17 at 17:00
• @DukeZhou I think textual classification algorithm..can work in that scenario. – quintumnia Aug 16 '17 at 16:36

## 2 Answers

Impossible to solve until you define an error measurement ( by example |R-R'| or (R-R')^2 ) and how this error changes when A, B and C change.

Extreme example: R is random (unrelated to A, B, C values) but static. Given some values to A, B, C, you can only answer the value of R(A,B,C) if A,B,C was in the training set. R(A,B,C) is undefined if A,B,C was not in the training set.

Moreover, improvements can be done if R has some properties, by example, if it is possible to state that R(A,B,C)=R(B,A,C) or R(A1,B2,C2)=R(A2,B2,C2) if A1+B1+C1=A2+B2+C2.

Without seeing more data it's hard to say for sure. Superficially, this looks like a regression type problem. As you mention, there is a lot of spread on the input values, but that doesn't necessarily mean that something like linear regression wouldn't work. Try it and see what kind of coefficient of correlation you get. If it's really low, you probably need a different approach, OR the data might actually not have any (or much) predictive power in this scenario.

Beyond linear regression, you might find that there's a more complicated mathematical relationship between the inputs and outputs, that could be determined using symbolic regression. Another possibility, if there is a complex non-linear relationship in play, is that an artificial neural network approach might work well.