tag:blogger.com,1999:blog-2198942534740642384.post5375055552337835585..comments2023-10-24T03:16:41.009-07:00Comments on Econometrics Beat: Dave Giles' Blog: Correlation Isn't Necessarily TransitiveDave Gileshttp://www.blogger.com/profile/05389606956062019445noreply@blogger.comBlogger8125tag:blogger.com,1999:blog-2198942534740642384.post-83200036990021310862016-10-12T04:23:12.969-07:002016-10-12T04:23:12.969-07:00I am sorry, but I also can't understand this e...I am sorry, but I also can't understand this example:<br />Pearson's product-moment correlation coefficient for sample data:<br />corr(x,y)= Σ[(Xi - X*)(Yi - Y*)] / {[Σ(Xi - X*)2][Σ(Yi - Y*)2]}1/2<br /><br />u*=(1+0)/2=0.5<br />v*=(1/sqrt(2)+1/sqrt(2))/2=1/sqrt(2)<br />w*=(0+1)/2=0.5<br />Then corr(u,v)=[(1-0.5)*{1/sqrt(2)-1/sqrt(2)}+(0-0.5)*{1/sqrt(2)-1/sqrt(2)}]/<br />/ [{(1-0.5)^2+(0-0.5)^2}*{{1/sqrt(2)-1/sqrt(2)}^2+{1/sqrt(2)-1/sqrt(2)}^2}]^(1/2) = 0<br />corr(v, w)=0<br />corr(u,w)=[(1-0.5)*(0-0.5)+(0-0.5)*(1-0.5)] /<br />/ [{(1-0.5)^2+(0-0.5)^2}*{(0-0.5)^2+(1-0.5)^2}]^(1/2)=<br />[-0.25-0.25]/[0.5*0.5]^(1/2)=-1<br />This result seems obvious to me. So, there is no correlation between u and v and between v and w, but corr(u,w)=-1.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-2198942534740642384.post-71768713890612450532016-01-06T09:42:58.592-08:002016-01-06T09:42:58.592-08:00My pleasure! I really enjoy reading your blog.My pleasure! I really enjoy reading your blog.Anonymoushttps://www.blogger.com/profile/18364835381103668758noreply@blogger.comtag:blogger.com,1999:blog-2198942534740642384.post-68181321346311483172016-01-02T11:44:02.853-08:002016-01-02T11:44:02.853-08:00Interesting, especially since causality is transit...Interesting, especially since causality is transitive -- causality behaves as a peculiar case of logical implication (i.e., a cause is a sufficient, yet not always necessary condition for its effect).<br /><br />I wonder if we could use it to argue about causality somehow.Stéphanenoreply@blogger.comtag:blogger.com,1999:blog-2198942534740642384.post-63050264467105309402015-12-29T09:24:26.845-08:002015-12-29T09:24:26.845-08:00The correlation is the dot product of the vectors ...The correlation is the dot product of the vectors - see this post: http://davegiles.blogspot.ca/2015/12/bounds-for-pearson-correlation.htmlDave Gileshttps://www.blogger.com/profile/05389606956062019445noreply@blogger.comtag:blogger.com,1999:blog-2198942534740642384.post-14975696903099277882015-12-29T09:15:04.479-08:002015-12-29T09:15:04.479-08:00Branko thanks for this.Branko thanks for this.Dave Gileshttps://www.blogger.com/profile/05389606956062019445noreply@blogger.comtag:blogger.com,1999:blog-2198942534740642384.post-23058828735859241392015-12-29T08:29:49.765-08:002015-12-29T08:29:49.765-08:00Given a correlation between X and Y, and between Y...Given a correlation between X and Y, and between Y and Z, it is interesting to compute the limits of correlation between X and Z (say, by computing the covariance matrix and requiring it to be semi-definite). The implications are quite stunning.<br /><br />For example, if cor(X,Y) = 0.5 and cor(Y,Z) = 0.5, the minimum of cor(X,Z) is -0.5 (with a negative sign; the maximum is, of course, 1)! This should come as no surprise, since the correlation is, by its properties, and Euclidian distance, so the transitivity need not apply.<br /><br />BTW, this actually happens quite often in the world of commodity prices, although not quite so drastically.Anonymoushttps://www.blogger.com/profile/18364835381103668758noreply@blogger.comtag:blogger.com,1999:blog-2198942534740642384.post-70900889561012863262015-12-29T01:49:49.583-08:002015-12-29T01:49:49.583-08:00I do not quite get the three unit vectors example....I do not quite get the three unit vectors example. v is a constant, so it should be uncorrelated with anything. The pair u and w constitutes a basic example of perfect negative correlation. (R software shows that corr(u,w)=-1, as expected, while corr(u,v) and corr(v,w) are undefined.)Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-2198942534740642384.post-19512205597228412092015-12-28T11:38:49.825-08:002015-12-28T11:38:49.825-08:00nice post
a more general example: A, B are iid an...nice post<br /><br />a more general example: A, B are iid and C = A + B, then A ~ C ~ B but A !~ B<br /><br />i first became aware of this when i learnt about Instrumental Variables in econometrics class<br /><br />an instrument Z is valid if it is correlated with X but not with e in the regression<br /><br />Y = XB + e<br /><br />which is to say that Z ~ X ~ e but Z !~ e, a violation of transitivitysamhttps://www.blogger.com/profile/10901506008348100808noreply@blogger.com