Skip to Main Content Skip to Search
Product Documentation

ispref - Test for existence of preference

Syntax

ispref('group','pref')
ispref('group')
ispref('group',{'pref1','pref2',...'prefn'})

Description

ispref('group','pref') returns 1 if the preference specified by group and pref exists, and 0 otherwise.

ispref('group') returns 1 if the GROUP exists, and 0 otherwise.

ispref('group',{'pref1','pref2',...'prefn'}) returns a logical array the same length as the cell array of preference names, containing 1 where each preference exists, and 0 elsewhere.

Examples

addpref('mytoolbox','version','1.0')
ispref('mytoolbox','version')

ans =
     1.0

See Also

addpref | getpref | rmpref | setpref | uigetpref | uisetpref

  


Free MATLAB Interactive Kit

Explore how to use MATLAB to make advancements in engineering and science.


Download free kit

Trials Available

Try the latest version of MATLAB and other MathWorks products.


Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS