How to change r code to Matlab
Ältere Kommentare anzeigen
I have a code for linear fit in r that I want to do in matlab. I have converted up to this point and then not exactly sure how to do the rest.
This is a simple linear regression in r that uses the lm function that is "linearmodel" to create a simple linear regression model
fit=lm(dependant variable ~ indepentand varible)
the reture should be the coefficients of the model
Is there a way to do this in matlab
fit <- lm((log(obs$O2)-log(0.247))~ obs$depth + 0)
2 Kommentare
dpb
am 5 Apr. 2019
My R syntax is too rusty...what's the wanted model in something can decipher?
Walter Roberson
am 5 Apr. 2019
depth to be fit to O2^0.247 ??
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Linear Algebra finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!