Hi
Running fs2000k2a.mod I encountered an error
??? Undefined command/function 'bsxfun'.
Error in ==> disp_moments at 48 y = bsxfun(@minus, y, m);
any ideas why bsxfun is missing or what was intended?
Hi George: bsxfun is a built-in matlab function, which should be availabe in recent versions of matlab. It is an element-by-element operator with automatic expansion of singleton dimensions. In the example below, bsxfun will substract m from y after expanding one of them if necessary. For instance if y has say k columns and m only one column, then bsxfun(@minus, y, m) is the same as y-repmat(m,1,k);
Junior
On Wed, Feb 17, 2010 at 1:17 PM, George Perendia < george@perendia.orangehome.co.uk> wrote:
Hi
Running fs2000k2a.mod I encountered an error
??? Undefined command/function 'bsxfun'.
Error in ==> disp_moments at 48 y = bsxfun(@minus, y, m);
any ideas why bsxfun is missing or what was intended?
--
Best regards George 07951415480
Dev mailing list Dev@dynare.org https://www.dynare.org/cgi-bin/mailman/listinfo/dev
Hi George,
bsxfun is a matlab mex file (I use this function intensively for the particle filers because it is much faster than repmat). This function appeared in matlab 7.4, so I guess that your version of matlab is too old. I will write an m file for bsxfun (and put it in the missing subdirectory) to be used with matlab's version inferior to 7.4. Later I will write a mex file (I think we can start using the source of the octave dll).
Best, Stéphane.
George Perendia a écrit :
Hi
Running fs2000k2a.mod I encountered an error
??? Undefined command/function 'bsxfun'.
Error in ==> disp_moments at 48 y = bsxfun(@minus, y, m);
any ideas why bsxfun is missing or what was intended?
It is urgent to provide a Matlab implementation in missing subdirectory, but I wouldn't spend time writing a DLL implementation. The Matlab routine will be as fast as the Matlab expression with repmat() that we have been using until now. I don't think that we should spend time improving the efficiency of old versions of Matlab.
Best
Michel
Stéphane Adjemian wrote:
Hi George,
bsxfun is a matlab mex file (I use this function intensively for the particle filers because it is much faster than repmat). This function appeared in matlab 7.4, so I guess that your version of matlab is too old. I will write an m file for bsxfun (and put it in the missing subdirectory) to be used with matlab's version inferior to 7.4. Later I will write a mex file (I think we can start using the source of the octave dll).
Best, Stéphane.
George Perendia a écrit :
Hi
Running fs2000k2a.mod I encountered an error
??? Undefined command/function 'bsxfun'.
Error in ==> disp_moments at 48 y = bsxfun(@minus, y, m);
any ideas why bsxfun is missing or what was intended?
I agree.
Stéphane.
Michel Juillard a écrit :
It is urgent to provide a Matlab implementation in missing subdirectory, but I wouldn't spend time writing a DLL implementation. The Matlab routine will be as fast as the Matlab expression with repmat() that we have been using until now. I don't think that we should spend time improving the efficiency of old versions of Matlab.
Best
Michel
Stéphane Adjemian wrote:
Hi George,
bsxfun is a matlab mex file (I use this function intensively for the particle filers because it is much faster than repmat). This function appeared in matlab 7.4, so I guess that your version of matlab is too old. I will write an m file for bsxfun (and put it in the missing subdirectory) to be used with matlab's version inferior to 7.4. Later I will write a mex file (I think we can start using the source of the octave dll).
Best, Stéphane.
George Perendia a écrit :
Hi
Running fs2000k2a.mod I encountered an error
??? Undefined command/function 'bsxfun'.
Error in ==> disp_moments at 48 y = bsxfun(@minus, y, m);
any ideas why bsxfun is missing or what was intended?
Dev mailing list Dev@dynare.org https://www.dynare.org/cgi-bin/mailman/listinfo/dev