Linear Regression - Repeat Measurements

6 次查看(过去 30 天)
Hi Everyone,
I am fairly new to Matlab and have a problem using Linear Regression.
I have an experiment where I have taken multiple repeat measurements. To simplify my problem I have a 10 by 1 vector of predictor variables (independent variables) and a 10 by 5 matrix of response variables (dependent variables). I know that these data should follow a linear trend and I want to evaluate how linear they actually are.
I want to apply a robust least square fitting to the average of my dependent variables at each independent variable. I can do this using robustfit. My problem arises as I also would like to weight the least square fitting method by the variance of the dependent variables at each data point. I can't figure out how to do this.
Any help would be greatly appreciated!
Best,
Siri

回答(2 个)

Star Strider
Star Strider 2014-5-4
Repeated measures problems have their own statistical requirements. I agree with Tom Lane’s answer to: Setting weights for robustfit command because I can’t improve on it. See the documentation for glmfit for details.
  1 个评论
Star Strider
Star Strider 2014-5-4
After looking around the Statistics Toolbox functions for a few minutes, I suggest you see the documentation: Set Up Multivariate Regression Problems. It seems to be closest to what you need.
(I apologise for the delay ... GMT-6 here.)

请先登录,再进行评论。


Anna
Anna 2014-5-4
Hi Star Strider,
Thanks for your answer. I have had a look through the documentation for glmfit but I am still a bit confused how to use glmfit with multiple response variables (I assume that's how I would treat my repeat measurements?). Would you perhaps be able to give me an example code line? Do I need to use another function?
thanks,
Siri

Community Treasure Hunt

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

Start Hunting!

Translated by