Mercurial > repos > vipints > rdiff
annotate rDiff/src/locfit/m/lcv.m @ 1:08d3a6143873
Deleted selected files
author | vipints |
---|---|
date | Tue, 08 Oct 2013 06:54:25 -0400 |
parents | 0f80a5141704 |
children |
rev | line source |
---|---|
0 | 1 function g=lcv(varargin) |
2 % | |
3 % likelihood cross-validation. | |
4 % | |
5 % returned vector consists of log-likelihood, trace(H), trace(H'H) | |
6 % and cross-validated deviance (-2 * cross-validated log-likelihood). | |
7 % | |
8 % Author: Catherine Loader. | |
9 | |
10 fit = locfit(varargin{:},'ev','cros'); | |
11 rs = rsum(fit); | |
12 | |
13 df0 = rs(1); | |
14 df1 = rs(2); | |
15 llk = rs(3); | |
16 | |
17 g = [llk df0 df1 -2*llk]; | |
18 | |
19 return; |