[Solved] matlab Error: `Using exist to check

matlab Error: `Using exist to check

matlab Error: Using exist to check for a variable in the transparent workspace is not supported. To check for a function, folder, file, or class, specify the appropriate second input argument to exist: 'builtin', 'class', 'dir' or 'file'.

 

Solution:
Modify exist(savepath) to exist(savepath, ‘file’) (if it is to detect the existence of a file fill in file, otherwise replace file with one of ‘builtin’, ‘class’, ‘dir’ or ‘file’)

Read More: