Date: Jan 28, 2013 3:59 AM
Author: Jim Rockford
Subject: Looking for "publish" example for a function with input arguments.

I can't seem to find a straightforward example on using the "publish" function when it's a function being published that takes input arguments.

For example, I have the function z = myfunk(x,y)

The simple publish command >> publish('myfunk','doc')
of course doesn't work
because the input arguments x and y aren't known.

What is the syntax for specifying the input arguments x,y to publish this function?

The documentation just says
"Additional code to evaluate during publishing, specified as the comma-separated pair consisting of 'codeToEvaluate' and the string with the corresponding code. Use this option to specify code that does not appear in the MATLAB file, for example to set the value of an input argument for a function being published."

Sorry, but I find this too opaque absent a single clear example showing this syntax.

Thanks for the help.

JR