New install: Undefined function 'isstring' for input arguments of type 'char'.

I just installed Matlab 2015 and get the following error upon starting the program:
> In matlabrc (line 228)
Undefined function 'isstring' for input arguments of type 'char'.
Error in fileparts (line 41)
if isstring(file)
The same "Undefined function 'isstring'..." appears in a dialog box whenever I try to open any script or function. However I know that I have isstring...
>> which isstring
C:\Program Files\MATLAB\R2015a\toolbox\matlab\codetools\@mtree\isstring.m % mtree method
I have 2019a installed on my machine and it works perfectly fine.

 채택된 답변

I think you have a fileparts.m that you downloaded or wrote on your path ahead of the one included in MATLAB. When I opened release R2015a line 41 was:
ind = find(file == '/'|file == '\', 1, 'last');
Check which fileparts function you're running:
which -all fileparts

추가 답변 (1개)

madhan ravi
madhan ravi 2020년 7월 24일

0 개 추천

댓글 수: 2

Then why does 2015a need it to operate correctly? I didn't modify the matlabrc file
It’s because the function “isstring()” was introduced in 2016b you can’t use it in 2015a, I don’t know how to explain more clearly than this.

댓글을 달려면 로그인하십시오.

카테고리

도움말 센터File Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

질문:

2020년 7월 24일

답변:

2020년 7월 24일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by