Friday, July 31, 2009

doc

Display online documentation in MATLAB Help browser

Graphical Interface

As an alternative to the doc function, use the Help browser Search tab. Set the Search type to Function Name, type the function name, and click Go.

Syntax

  • doc
    doc function
    doc toolbox/
    doc toolbox/function

Description

doc opens the Help browser, if it is not already running.

doc function displays the reference page for the MATLAB function function in the Help browser. If function is overloaded, doc displays the reference page for the first function on the search path and lists the overloaded functions in the MATLAB Command Window. If a reference page for the function does not exist, doc displays M-file help in the Help browser.

doc toolbox/ displays the Roadmap page, a summary of the most pertinent documentation for toolbox, in the Help browser.

doc toolbox/function displays the reference page for function that belongs to the specified toolbox, in the Help browser.



docopt

Display location of help file directory for UNIX platforms

Syntax

  • docopt
    [doccmd,options,docpath] = docopt

Description

docopt displays the location of the online help files directory (online documentation location) for UNIX platforms if the web function is used with the -browser option. It is also used for UNIX platforms that do not support Java GUIs--see the "Release 13 Release Notes for more information about these platforms. You specify where the online help directory will be located when you install MATLAB. It can be on a disk or CD-ROM drive in your local system. If you relocate your online help file directory, edit the docopt.m file, changing the location in it. (For Windows and the UNIX platforms that support Java GUIs, select File -> Preferences -> Help to view or change the documentation location.)

[doccmd,options,docpath] = docopt displays three strings: doccmd, options, and docpath.


doccmd
The function that doc uses to display MATLAB documentation. The default is netscape.
options
Additional configuration options for use with doccmd.
docpath
The path to the MATLAB online help files. If docpath is empty, the doc function assumes the help files are in the default location.

Remarks

To globally replace the online help file directory location, update $matlabroot/toolbox/local/docopt.m.

To override the global setting, copy $matlabroot/toolbox/local/docopt.m to $HOME/matlab/docopt.m and make changes there. For the changes to take effect in the current MATLAB session, $HOME/matlab must be on your MATLAB path.



docroot

Get or set root directory for MATLAB help files

Graphical Interface

As an alternative to the docroot function, select File -> Preferences -> Help and set the Documentation location.

Syntax

  • docroot
    docroot('newdocroot')
    docroot(newdocroot, 'cdrom')

Description

docroot displays the current value for docroot, the root directory for MATLAB help files. This is the directory where the MATLAB Help browser looks for the online documentation to display.

docroot('newdocroot') sets the root directory for MATLAB help files to newdocroot, where newdocroot is the full pathname to the help directory. For example, type docroot('d:/matlabr13/help'). One useful application is setting docroot in your startup.m file.

docroot('newdocroot', 'cdrom') sets the root directory for MATLAB help files on the MATLAB documentation CD to newdocroot, where newdocroot is the full pathname to the help directory on your MATLAB documentation CD. For example, type docroot('z:/help', 'cdrom').

Examples

You can include a docroot statement in your startup.m file.

No comments:

Post a Comment