How to troubleshoot "Undefined function or variable 'xticks'." on MATLAB R2016a.

Getting "Undefined function or variable 'xticks'." on MATLAB R2016a on my home laptop. Script works perfectly fine on my work computer. Please advise.

 採用された回答

Geoff Hayes
Geoff Hayes 2017 年 8 月 20 日
According to xticks, then function was introduced in MATLAB R2016b. Your work computer must be at least on version R2016b. On your version, you may need to do something like
get(hAxes, 'XTick')
to get the current x-ticks for your axes given the handle hAxes, and
set(hAxes, 'XTick', ...)

5 件のコメント

tsylk
tsylk 2017 年 8 月 20 日
Thanks a lot - used the version provided in your link! Got 'XTick' and 'xticks' mixed up while looking for answers.
Diah Junaidi
Diah Junaidi 2017 年 12 月 3 日
How about this one sir,
Undefined function or variable 'getWorkArea'.
Error in images.internal.initSize (line 53)
w = getWorkArea;
Error in imshow (line 309)
images.internal.initSize(hh,initial_mag/100,is_border_tight)
Error in fcm_seg (line 8)
figure, imshow(Img), title('Original image');
Which MATLAB release are you using?
toolbox/matlab/images/+images/+internal/initSize.m exists from R2014b, but the relevant code line is
wa = images.internal.getWorkArea;
in all of those versions.
In R2011a to R2014a, toolbox/images/imuitools/private/initSize.m has the line
wa = getWorkArea;
referring to toolbox/images/imuitools/private/getWorkArea.m
For the R2010bSP1 that I happen to have installed, I did not happen to install Image Processing Toolbox
Brando Miranda
Brando Miranda 2018 年 5 月 11 日
weird I get this error but I have 2017b...
What shows up for
which -all imshow
I just re-checked R2017b and confirmed that initSize calls upon images.internal.getWorkArea rather than upon getWorkArea

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeIntroduction to Installation and Licensing についてさらに検索

製品

質問済み:

2017 年 8 月 20 日

コメント済み:

2018 年 5 月 11 日

Community Treasure Hunt

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

Start Hunting!

Translated by