https://au.mathworks.com/help/matlab/ref/matlab.settings.settingsgroup.hasgroup.html
hasGroup - Determine if settings group exists - MATLAB
This MATLAB function returns 1 if the settings group parentgroup contains a settings group called name.
determinesettingsgroupexistsmatlab