-
Notifications
You must be signed in to change notification settings - Fork 17
147 lines (133 loc) · 5.76 KB
/
dynare-6.2-matlab-r2024b-ubuntu.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
name: 'Ubuntu '
on:
push:
branches:
- 'main'
workflow_dispatch:
jobs:
dynare_6_2_matlab_r2024b_ubuntu:
runs-on: ubuntu-22.04
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up MATLAB
uses: matlab-actions/setup-matlab@v2
with:
release: R2024b
products: Symbolic_Math_Toolbox Statistics_and_Machine_Learning_Toolbox Optimization_Toolbox Econometrics_Toolbox Parallel_Computing_Toolbox Control_System_Toolbox Global_Optimization_Toolbox
cache: true
- name: Rename libraries and fix issues (as in matlab-support package)
run: |
if [ -f "/opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libgcc_s.so.1" ]; then \
mv /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libgcc_s.so.1 /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libgcc_s.so.1.bak; \
fi
if [ -f "/opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libstdc++.so.6" ]; then \
mv /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libstdc++.so.6 /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libstdc++.so.6.bak; \
fi
if [ -f "/opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libgfortran.so.5" ]; then \
mv /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libgfortran.so.5 /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libgfortran.so.5.bak; \
fi
if [ -f "/opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libquadmath.so.0" ]; then \
mv /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libquadmath.so.0 /opt/hostedtoolcache/MATLAB/2024.2.999/x64/sys/os/glnxa64/libquadmath.so.0.bak; \
fi
if [ -f "/opt/hostedtoolcache/MATLAB/2024.2.999/x64/bin/glnxa64/libfreetype.so.6" ]; then \
mv /opt/hostedtoolcache/MATLAB/2024.2.999/x64/bin/glnxa64/libfreetype.so.6 /opt/hostedtoolcache/MATLAB/2024.2.999/x64/bin/glnxa64/libfreetype.so.6.bak; \
fi
if [ -f "/opt/hostedtoolcache/MATLAB/2024.2.999/x64/bin/glnxa64/libtiff.so.5" ]; then \
mv /opt/hostedtoolcache/MATLAB/2024.2.999/x64/bin/glnxa64/libtiff.so.5 /opt/hostedtoolcache/MATLAB/2024.2.999/x64/bin/glnxa64/libtiff.so.5.bak; \
fi
- name: Install dependencies for Dynare
run: |
sudo apt-get update
sudo apt-get install -y gcc g++ meson pkgconf python3-pip gfortran \
libboost-graph-dev libgsl-dev libmatio-dev libslicot-dev libslicot-pic \
libsuitesparse-dev flex libfl-dev bison texlive texlive-publishers \
texlive-latex-extra texlive-fonts-extra texlive-font-utils texlive-latex-recommended \
texlive-science texlive-plain-generic lmodern python3-sphinx tex-gyre latexmk \
libjs-mathjax x13as liboctave-dev octave-control octave-econometrics octave-io \
octave-statistics octave-struct octave-parallel gnuplot fonts-freefont-otf \
ghostscript epstool git git-lfs
- name: Compile Dynare
run: |
export GIT_CLONE_PROTECTION_ACTIVE=false
git clone --depth 1 --branch 6.2 --recurse-submodules https://git.dynare.org/dynare/dynare.git
cd dynare
pip3 install meson==1.3.1
export PATH="/home/matlab/.local/bin:${PATH}"
meson setup -Dmatlab_path=/opt/hostedtoolcache/MATLAB/2024.2.999/x64 -Dbuildtype=debugoptimized build-matlab
meson compile -C build-matlab
cd ..
- name: Run week 1 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
quickTourMatlab;
- name: Run week 2 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
visualizingTimeSeriesDataNorway;
definitionFrequenciesTimeSeriesData;
whiteNoisePlots;
plotsAR1;
- name: Run week 3 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
acfPlots_run;
lawOfLargeNumbers;
lawOfLargeNumbersAR1;
centralLimitDependentData;
- name: Run week 4 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
AR4OLS;
AR4ML;
AR1MLLaplace;
- name: Run week 5 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
AR4LagSelection;
portmanteauTest;
bootstrapCIAR1;
- name: Run week 6 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
matrixAlgebraEigenvalues;
matrixAlgebraKroneckerFormula;
matrixAlgebraRotation;
matrixAlgebraCholesky;
matrixAlgebraLyapunovComparison;
VARpDimensionsIllustration;
threeVariableVAROLS;
threeVariableVARML;
- name: Run week 7 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
USOil;
- name: Run week 9 codes
uses: matlab-actions/run-command@v2
with:
command: |
addpath("dynare/matlab");
cd("progs/matlab");
keatingSR;
BlanchardQuahLR;