diff --git a/matlab/dynare_config.m b/matlab/dynare_config.m
index 3a39f8c4d270a8a6e0a0e516490f37a0609511b0..1808bc872d45d406d8faa80b367aa746e8fc60aa 100644
--- a/matlab/dynare_config.m
+++ b/matlab/dynare_config.m
@@ -48,6 +48,8 @@ addpath([dynareroot '/AIM/'])
 if ~exist('OCTAVE_VERSION')
     % Replacements for rows() and columns() (inexistent under MATLAB)
     addpath([dynareroot '/missing/rows_columns'])
+    % Replacement for vec() (inexistent under MATLAB)
+    addpath([dynareroot '/missing/vec'])
     if isempty(ver('stats'))
         % Replacements for functions of the stats toolbox
         addpath([dynareroot '/missing/stats/'])
diff --git a/matlab/vec.m b/matlab/missing/vec/vec.m
similarity index 100%
rename from matlab/vec.m
rename to matlab/missing/vec/vec.m