Katzlab dd76ab1d12 Added PTL2 Scripts
These are PTL2 files from Auden 2/9
2023-02-14 11:20:52 -05:00

12 lines
246 B
Matlab

function ll=LLC(U,D,CC)
% compute the log likelihood from u,dand data or from R and data
if (nargin==3)
if (min(size(U))==1)
A=U;
U=rotAll(A);
end
Qt = U' * expm(D) * U;
ll=sum(sum(log(Qt).*CC));
else
disp('cant do this');
end