Curve fitting with 3 variables

Hey guys,
so I am trying to find total base shear in a building as a function of storey height, total height, and load (kn/m). I have data of what the base shear becomes when I vary the three independent variables and what the resultant force is. I am new to MATLAB and therefore was wondering how I can plot this in MATLAB and get a formula/model which will predict approximately what value I will get for base shear.
I have done multiple linear regression in Excel but the formula I got was not as accurate as I had hoped. Any idea on how to use MATLAB for this?

Answers (1)

Star Strider
Star Strider on 15 Mar 2018
There are several ways, depending on what you want to do. I would begin with the Statistics and Machine Learning Toolbox regress (link) function.
If you do not have access to that Toolbox, start with the mldivide,\ (link) function. It will give you the regression coefficients, although not the related statistics.

Categories

Asked:

on 15 Mar 2018

Answered:

on 15 Mar 2018

Community Treasure Hunt

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

Start Hunting!