Date: Jan 18, 2013 10:12 AM
Author: Steven Lord
Subject: Re: Substitution of Operators



"Omid " <omid.yousefian88@gmail.com> wrote in message
news:kdbf2r$lfc$1@newscl01ah.mathworks.com...
> Hello everyone,
>
> I need to substitute one operator in my program with another operator (*.
> with *)
> but i do not know how it is possible.
> I would appreciate if anyone knows a function which do that.


Two possible approaches:

Open the file in the MATLAB Editor.
Use Find/Replace to perform the replacement.

or

Read the function file in as a text file.
Perform the replacement.
Write the modified text into a new function file.

The file I/O and string processing functions listed in the output of these
two commands will be useful to you for the second approach:

help iofun
help strfun

--
Steve Lord
slord@mathworks.com
To contact Technical Support use the Contact Us link on
http://www.mathworks.com