help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Linear regression


From: Doug Stewart
Subject: Re: Linear regression
Date: Tue, 13 May 2014 12:04:43 -0400




On Tue, May 13, 2014 at 10:35 AM, Juan Pablo Carbajal <address@hidden> wrote:
On Tue, May 13, 2014 at 4:26 PM, Hannibal Smith <address@hidden> wrote:
> % Add a column of all ones (intercept term) to x
> X = [ones(m, 1) x];
> % Calculate theta
> theta = (pinv(x'*x))*x'*y;

Your problem is in the lines above, check carefully where are you
storing the values and what are you using for your regression. Also,
your question is a borderliner, do not expect the community to worry
about your problems if you do not put an effort to write your mails
and make your debuging code readable and short (yeah, succinct)




X is different that x 
DAS


reply via email to

[Prev in Thread] Current Thread [Next in Thread]