Skip to content

Commit 6518028

Browse files
committed
updated licence and comments.
Former-commit-id: e225f92 [formerly e225f92 [formerly 58cf10c]] Former-commit-id: 20880175fb41e0b4e895e3d8500ad2c2c562ead3 Former-commit-id: c34bd13
1 parent 41545f7 commit 6518028

37 files changed

+112
-44
lines changed

README.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ See *LICENSE* for more information.
2424

2525
``` R
2626
##############################################################################
27-
#
28-
# Copyright (C) 2017 Johan Dahlin < liu (at) johandahlin.com.nospam >
29-
#
3027
# This program is free software; you can redistribute it and/or modify
3128
# it under the terms of the GNU General Public License as published by
3229
# the Free Software Foundation; either version 2 of the License, or
@@ -40,6 +37,5 @@ See *LICENSE* for more information.
4037
# You should have received a copy of the GNU General Public License along
4138
# with this program; if not, write to the Free Software Foundation, Inc.,
4239
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
43-
#
4440
##############################################################################
4541
```

matlab/README.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,6 @@ Copyright information
3535
--------------
3636
``` R
3737
##############################################################################
38-
#
39-
# Copyright (C) 2017 Johan Dahlin < liu (at) johandahlin.com.nospam >
40-
#
4138
# This program is free software; you can redistribute it and/or modify
4239
# it under the terms of the GNU General Public License as published by
4340
# the Free Software Foundation; either version 2 of the License, or
@@ -51,6 +48,5 @@ Copyright information
5148
# You should have received a copy of the GNU General Public License along
5249
# with this program; if not, write to the Free Software Foundation, Inc.,
5350
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
54-
#
5551
##############################################################################
5652
```

matlab/example1_lgss.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% State estimation in a LGSS model using particle and Kalman filters
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58

69
% Set random seed

matlab/example2_lgss.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% Example of particle Metropolis-Hastings in a LGSS model.
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58

69
% Set random seed

matlab/example3_sv.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% Example of particle Metropolis-Hastings in a stochastic volatility model
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58

69
% Set random seed

matlab/generateData.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% Generates data from the LGSS model
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58
function[states, observations] = generateData(parameters, noObservations, initialState)
69
states = zeros(noObservations+1, 1);

matlab/kalmanFilter.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% Kalman filtering
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58
function xHatFiltered = kalmanFilter(observations, parameters, initialState, initialStateCov)
69

matlab/particleFilter.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% Fully-adapted particle filter for the linear Gaussian SSM
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58
function[xHatFiltered, logLikelihood] = particleFilter(observations, parameters, noParticles, initialState)
69

matlab/particleFilterSVmodel.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% Bootstrap particle filter for the SV model
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58
function[xHatFiltered, logLikelihood] = particleFilterSVmodel(observations, parameters, noParticles)
69

matlab/particleMetropolisHastings.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22
% Particle Metropolis-Hastings (PMH) for the LGSS model
3-
% (c) Johan Dahlin 2017 under MIT license <liu@johandahlin.com.nospam>
3+
%
4+
% Johan Dahlin <liu (at) johandahlin.com.nospam>
5+
% Documentation at https://github.com/compops/pmh-tutorial
6+
% Published under GNU General Public License
47
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
58
function[phi] = particleMetropolisHastings(observations, initialPhi, parameters, noParticles, initialState, noIterations, stepSize)
69

0 commit comments

Comments
 (0)