Error using scatter3 (line 45) too many input arguments

I've been using scatter3 for quite a while in some functions and GUIs, and it has been working fine. Today, when I tried to use it, it's giving me the following error:
Error using scatter3 (line45) Too many input arguments
I haven't changed the number of input arguments at all in my functions/GUIs, and it worked before. Additionally, when I use the generic Matlab scatter3 example, I get the exact same error even though the number of inputs is fine.
Any help would be greatly appreciated!
I should also clarify that after getting the error, Matlab will plot a 2D graph (probably ignoring one of the variables?). When I open the scatter3.m file, there are suggestions that a function that checks the number of arguments will be updated in future versions. Could this be causing the issues?

回答 (1 件)

Star Strider
Star Strider 2014 年 11 月 30 日

0 投票

You probably have a variable or other function named scatter3 in your path or workspace.
Type:
which scatter3 -all
in the Command Window. If you get something other than:
C:\Program Files\MATLAB\R2014b\toolbox\matlab\specgraph\scatter3.m
you’re likely overshadowing it.

4 件のコメント

Jonathan
Jonathan 2014 年 11 月 30 日
Unfortunately, I thought this might be the case, but Matlab is using the correct scatter3.
Star Strider
Star Strider 2014 年 11 月 30 日
My other suggestion then is to rehash the path:
restoredefaultpath
rehash toolboxcache
If you’re curious about them, the documentation on them magically appears with these commands:
doc restoredefaultpath
doc rehash
Jonathan
Jonathan 2014 年 11 月 30 日
Thank you for the suggestion, but unfortunately it still doesn't fix the issue.
Star Strider
Star Strider 2014 年 11 月 30 日
編集済み: Star Strider 2014 年 11 月 30 日
My pleasure. Sorry, though. I’m out of ideas.
It’s likely time to contact Tech Support.

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

カテゴリ

ヘルプ センター および File ExchangeStartup and Shutdown についてさらに検索

タグ

質問済み:

2014 年 11 月 30 日

編集済み:

2014 年 11 月 30 日

Community Treasure Hunt

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

Start Hunting!

Translated by