Revision 745, 0.7 kB
(checked in by smidl, 15 years ago)
|
examples on windows
|
-
Property svn:eol-style set to
native
|
Line | |
---|
1 | % name random variables |
---|
2 | y = RV({'y'},1); |
---|
3 | u = RV({'u'},1); |
---|
4 | |
---|
5 | % create f(y_t| y_{t-3}, u_{t-1}) |
---|
6 | fy.class = 'mlnorm<ldmat>'; |
---|
7 | fy.rv = y; |
---|
8 | fy.rvc = RVtimes([y,u], [-3, -1]); |
---|
9 | fy.A = [0.5, -0.9]; |
---|
10 | fy.const = 0; |
---|
11 | fy.R = 1e-2; |
---|
12 | |
---|
13 | % create f(u_t| ) |
---|
14 | fu.class = 'enorm<ldmat>'; |
---|
15 | fu.rv = u; |
---|
16 | fu.mu = 0; |
---|
17 | fu.R = 1e-1; |
---|
18 | |
---|
19 | % create DS |
---|
20 | DS.class = 'PdfDS'; |
---|
21 | DS.pdf.class = 'mprod'; |
---|
22 | DS.pdf.pdfs = {fy, fu}; |
---|
23 | DS.init_rv = RVtimes([y,y,y], [-1,-2,-3]); |
---|
24 | DS.init_values = [0.1, 0.2, 0.3]; |
---|
25 | |
---|
26 | experiment.ndat=100; |
---|
27 | |
---|
28 | %M=estimator(DS,{},experiment); |
---|
29 | M=estimator(DS,{},experiment); |
---|
30 | |
---|
31 | %%% store results |
---|
32 | Data=[M.DS_y'; M.DS_u']; |
---|
33 | drv = RVjoin([y,u]); |
---|
34 | true_theta=[fy.A fy.const]; |
---|
35 | true_R=[fy.R]; |
---|
36 | save pdfds_results Data drv y u true_theta true_R |
---|