Error launching Osprey GUI

Hi all,

I am trying to launch the Osprey GUI as explained in the Osprey documentation (4.1). When I input the command “Osprey”, I get the following error:

Unable to resolve the name uiw.utility.loadIcon.

Error in Osprey (line 31)
logoBanner = uiw.utility.loadIcon(logoFcn);

Error in Osprey_testing (line 4)
Osprey

Here is the code for 30 and 31 of the Osprey function, which is where the error is coming from:
logoFcn = @()imread(‘osprey.png’, ‘BackgroundColor’, gui.colormap.Background);
logoBanner = uiw.utility.loadIcon(logoFcn);

Could anyone help me out with this? I am new to Matlab so any help would be appreciated. I have downloaded Osprey and spm12 and added their folders to the path, so I don’t think that’s the issue.

Thanks!

Hi @clo,

Thanks for reaching out. Did you also download the GUI Layout and the Widgets Toolbox from the MATLAB file exchange as described Chapter 1 Getting started | osprey-documentation.utf8?

The error seems to infer that Matlab doesn’t know this specific command which is related to the Widgets toolbox used for the GUI.

Please let me know if this solves the issues.

Best,
Helge

Hi Helge,

Thank you for your prompt response! I made sure the required the Widgets and GUI toolboxes are installed, and it seems for some reason that although both are installed, the Widgets toolbox does not show up when I use the “ver” command to double check. However, the Widgets Compatibility support does.

When I run “Osprey,” it now displays the Osprey pop-up, but then runs the error:
Unrecognized function or variable ‘osp_platform’.

Error in Osprey (line 37)
font=osp_platform(‘fonts’);

I am assuming this has to do with the toolboxes.
Thank you very much for all of your help!

Hi @clo,

This sounds like Osprey is not included in the MATLAB path. You could run those two lines before calling Osprey:

% Osprey SPM Setup
addpath(genpath('/Users/helge/Documents/GitHub/osprey'));
addpath('/Users/helge/Documents/GitHub/osprey/spm12');

You’ll have to change the path to your Osprey and SPM folder. I think this will solve your issue.

Best,
Helge