Borrar filtros
Borrar filtros

Multiple linear regression with excel data in Matlab

3 visualizaciones (últimos 30 días)
Betty
Betty el 27 de Nov. de 2017
Comentada: Betty el 27 de Nov. de 2017
I'm trying to do a multiple linear regression to predict my (Y) column. I have imported my data from excel and have a 10x8 double matrix. How can I predict 1(Y) when having 6(X)? (my first column is not important in this matter as it's number going from 1-10.)
I want to use this function: [b,bint,r] = regress(y,X)
Hope this makes sense.
  2 comentarios
John D'Errico
John D'Errico el 27 de Nov. de 2017
10 data points, 6 independent variables as predictors, plus a constant probably in the model.
Have you tried using regress? It is what you want to use. It will be a complete waste of time because you have almost certainly wildly too little data. But you can use regress.
READ THE HELP FOR REGRESS. How will us retyping the documentation for regress make it any easier for you to use?
As I said, you have too little data to generate a useful model. But if you really want to compute useless garbage in the form of a model, go for it.
Betty
Betty el 27 de Nov. de 2017
I have larger data with 330x8 including 33 subjects, but I wanted to try it on the first one to test if it was working.
Any ideas how to code it now? I used xlread so I have all my data in my workspace.

Iniciar sesión para comentar.

Respuestas (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by