Skip to content

Commit 7d7c3aa

Browse files
committed
make code consistent for linRegVb and rvmRegVb
1 parent 5b53e9c commit 7d7c3aa

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

chapter10/linRegVb.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
KLw = -sum(log(diag(U)));
4747
% q(alpha)
4848
w2 = dot(Ew,Ew);
49-
invU = U\I;
49+
invU = U'\I;
5050
trS = dot(invU(:),invU(:));
5151
b = b0+0.5*(w2+trS); % 10.95
5252
Ealpha = a/b; % 10.102

chapter10/rvmRegVb.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
KLw = -sum(log(diag(U)));
5050
% q(alpha)
5151
w2 = Ew.*Ew;
52-
invU = U\I;
52+
invU = U'\I;
5353
dgS = dot(invU,invU,2);
5454
b = b0+0.5*(w2+dgS);
5555
Ealpha = a./b;

0 commit comments

Comments
 (0)