# How to predict single y target based on several X values? [duplicate]

I try to predict the result of an personality type test based on how people answered. My sample consists of the answers which range from 1 (strongly disagree) to 7 (strongly agree). Six answers lead to a result. I have the results and answers of 80 people.

An example of my dataset looks like this:

Patrick 2 4 7 1 3 4 76%
... ... ... ... ... ... ... ...
Stefanie 1 7 7 6 5 6 93%

I guess I could use multiple interpolation or curve fitting. Does someone know matching python functions for that?

• This is known as a regression problem. Perhaps that's what you might mean by "multiple interpolation"?
– whuber
Commented Apr 16, 2022 at 20:24
• Your problem statement is not clear. Is "Result" a function of how the subjects answered questions Q1-Q6? How do you measure Result? Commented Apr 16, 2022 at 21:03
• I am not sure if it is a regression problem. Regression predicts on given X values one target y. I want to do it the other way around. Given y how to predict X. In my case X are the values which represent the answer to an question (1 - strongly disagree & 7 - strongly agree). @whuber
– yemy
Commented Apr 16, 2022 at 21:47
• Thank you! I added some more information and hope it's clear now. Indeed the "Result" is a function based on the subjects answered questions. @dipetkov
– yemy
Commented Apr 16, 2022 at 21:53
• You are right. I had a understanding problem. I just apply multiple regression on my existing data. Thank you. @whuber
– yemy
Commented Apr 17, 2022 at 2:07