Skip to main content
Tweeted twitter.com/#!/StackProgrammer/status/648840923896541185
edited tags
Link
manlio
  • 4.3k
  • 3
  • 28
  • 38
Source Link
kettch
  • 153
  • 3

Algorithm for predicting outcome based on parameters

I've never done anything with statistics, so I'm unsure of how to start with this problem that I need to solve for some software that I'm working on.

Basically, there are three parameters

  1. An integer parameter (A) that can be a range of (for the sake of argument) 1-10
  2. A Boolean parameter (B) that if present weights the value of A.
  3. An integer parameter (C) that can be a range of 1-100.

There is one outcome: An integer (D) that can be of the range -1, 0, 1.

For each value of C, there will be one value of A, B, and D. C is a preexisting condition. A, and B are parameters. D is the outcome, which may be subjective.

+---+----+---+----+
| C | A  | B | D  |
+---+----+---+----+
| 1 |  3 | 0 | -1 |
| 1 |  3 | 1 | -1 |
| 1 |  5 | 0 |  0 |
| 1 |  5 | 0 |  0 |
| 1 | 10 | 0 |  1 |
| 1 | 10 | 1 |  1 |
| 2 |  3 | 0 | -1 |
| 2 |  3 | 1 |  0 |
| 2 |  4 | 0 |  0 |
| 2 |  4 | 1 |  0 |
+---+----+---+----+

What I'm looking for, is given C, A, B, how can I make a prediction of what D will be. In this case, I will have historical data of all four values to go from. C won't necessarily be linear as in my example.