Function File: publish (filename)
Function File: publish (filename, options)
Produces latex reports from scripts.
publish (my_script)where the argument is a string that contains the file name of the script we want to report.
If two arguments are given, they are interpreted as follows.
publish (filename, [option, value, ...])The following options are available:
- format
the only available format values are the strings `latex' and `html'.
- imageFormat:
string that specifies the image format, valid formats are `pdf', `png', and `jpg'(or `jpeg').
- showCode:
boolean value that specifies if the source code will be included in the report.
- evalCode:
boolean value that specifies if execution results will be included in the report.
Default options
- format = latex
- imageFormat = pdf
- showCode = 1
- evalCode = 1
Remarks
- Any additional non-valid field is removed without notification.
- To include several figures in the resulting report you must use figure with a unique number for each one of them.
- You do not have to save the figures manually, publish will do it for you.
- The functions works only for the current path and no way ... to specify other path is allowed.
Assume you have the script `myscript.m' which looks like
x = 0:0.1:pi; y = sin(x) figure(1) plot(x,y); figure(2) plot(x,y.^2);You can then call publish with default options
publish("myscript")
Package: miscellaneous