現在この質問をフォロー中です
- フォローしているコンテンツ フィードに更新が表示されます。
- コミュニケーション基本設定に応じて電子メールを受け取ることができます。
cannot plot (Warning: The Position specified is invalid)
3 ビュー (過去 30 日間)
古いコメントを表示
DIA Matlab License manager
2018 年 10 月 9 日
Suddenly, I'm no longer able to plot, or create figures. When I issue one of the following commands
hold on
or
figure
or
plot(1,1) % just to plot a point
I get the following warning:
Warning: The Position specified is invalid
a figure window is then created, as in the figure, but no plots are created in it.
11 件のコメント
Adam
2018 年 10 月 9 日
Have you tried restarting matlab?
You may want to try:
rehash toolboxcache
on command line also.
Alessandro Cuttin
2018 年 10 月 9 日
Can't say why, but suddenly Matlab seemed broken (just creating a variable a=1 caused an error to be displayed), so I re-installed it. This plot problem still persists, also after restarting the program.
Alessandro Cuttin
2018 年 10 月 9 日
The problem still persists
>> close all
>> rehash toolboxcache
>> hold on
Warning: The Position specified is invalid
> In hold (line 37)
Alessandro Cuttin
2018 年 10 月 9 日
btw: I'm the one who asked the question, It's just that now I'm using my personal account, rather than the institutional one.
Adam
2018 年 10 月 9 日
What does
which figure -all
show?
Have you written any of your own functions using the same names as builtins such as figure, hold, plot?
Alessandro Cuttin
2018 年 10 月 9 日
>> which figure -all
built-in (/opt/MATLAB/R2018a/toolbox/matlab/graphics/figure)
>>
I do have one function in the script I'm currently working on, but reserved names like figure, hold and plot are not used. The warning is issued even if the workspace is empty.
Steven Lord
2018 年 10 月 9 日
What do these commands return?
which -all gca
which -all axes
which -all get
Jan
2018 年 10 月 9 日
編集済み: Jan
2018 年 10 月 9 日
Where does the warning come from? Use the debugger to check this:
dbstop if warning
If "a=1 caused an error" then please post the error message.
Whenever a description contains the term "suddenly", the user has changed something important, that he was not aware of. It might be the default units of figures in your case. If you re-install Matlab, the contents or the preferences folders is not changed: prefdir. Try to rename the preferences and check, if Matlab works after an automatic recreation.
In addition a user-defined startup.m file is not cleared also, but there you might find a re-definition of the factory or default properties of figures. But why "a=1" causes errors is mysterious. Maybe this gets clear, if you show us the message.
Alessandro Cuttin
2018 年 10 月 9 日
In response to @Steven, these are the output:
>> clear all
>> which -all gca
built-in (/opt/MATLAB/R2018a/toolbox/matlab/graphics/gca)
>> which -all axes
built-in (/opt/MATLAB/R2018a/toolbox/matlab/graphics/axes)
>> which -all get
built-in (/opt/MATLAB/R2018a/toolbox/matlab/graphics/get)
get is a built-in method % matlab.ui.internal.mixin.Printable method
get is a built-in method % matlab.ui.internal.mixin.Windowable method
get is a built-in method % matlab.ui.Figure method
get is a built-in method % matlab.ui.internal.mixin.AutoResizable method
get is a built-in method % matlab.ui.internal.mixin.AxesLimits method
get is a built-in method % matlab.ui.internal.mixin.Legacy method
get is a built-in method % matlab.ui.internal.mixin.FontRenderable method
get is a built-in method % matlab.ui.internal.mixin.KeyInvokable method
get is a built-in method % matlab.ui.internal.mixin.NoMarginsUnitsOnlyPositionable method
get is a built-in method % matlab.ui.internal.mixin.Positionable method
get is a built-in method % matlab.ui.internal.mixin.Selectable method
get is a built-in method % matlab.ui.internal.mixin.TerminalStateRepresentable method
get is a built-in method % matlab.ui.Root method
get is a built-in method % matlab.ui.control.ClientComponent method
get is a built-in method % matlab.ui.control.Component method
get is a built-in method % matlab.ui.container.Container method
get is a built-in method % matlab.ui.container.CanvasContainer method
get is a built-in method % matlab.ui.control.WebComponent method
get is a built-in method % matlab.ui.control.UIControl method
get is a built-in method % matlab.ui.container.Menu method
get is a built-in method % matlab.ui.container.toolbar.PushTool method
get is a built-in method % matlab.ui.container.toolbar.ToggleSplitTool method
get is a built-in method % matlab.ui.container.toolbar.ToggleTool method
get is a built-in method % matlab.ui.internal.mixin.UIToggleToolMixin method
get is a built-in method % matlab.ui.internal.mixin.UIToolMixin method
get is a built-in method % matlab.ui.container.Toolbar method
get is a built-in method % matlab.graphics.Graphics method
get is a built-in method % matlab.graphics.GraphicsPlaceholder method
get is a built-in method % matlab.graphics.internal.GraphicsPropertyHandler method
get is a built-in method % matlab.graphics.internal.ReferenceObject method
get is a built-in method % matlab.graphics.mixin.GraphicsPickable method
get is a built-in method % matlab.graphics.mixin.Mixin method
get is a built-in method % matlab.graphics.mixin.NodeChildren method
get is a built-in method % matlab.graphics.mixin.NodeParent method
get is a built-in method % matlab.graphics.mixin.Pickable method
get is a built-in method % matlab.graphics.mixin.Selectable method
get is a built-in method % matlab.graphics.internal.GraphicsBaseFunctions method
get is a built-in method % matlab.graphics.internal.GraphicsUIProperties method
get is a built-in method % matlab.graphics.internal.GraphicsCoreProperties method
get is a built-in method % matlab.graphics.internal.Legacy method
get is a built-in method % matlab.mixin.SetGet method
get is a built-in method % hgsetget method
get is a Java method % java.util.ArrayList method
get is a Java method % java.util.AbstractList method
get is a Java method % java.util.List method
get is a built-in method % matlab.graphics.primitive.canvas.JavaCanvasFactory method
get is a built-in method % matlab.graphics.primitive.canvas.JavaCanvas method
get is a built-in method % matlab.graphics.axis.AbstractAxes method
get is a built-in method % matlab.graphics.axis.Axes method
get is a built-in method % matlab.graphics.axis.decorator.AxisDecoration method
get is a built-in method % matlab.graphics.axis.decorator.AxisRulerBase method
get is a built-in method % matlab.graphics.axis.decorator.Backdrop method
get is a built-in method % matlab.graphics.axis.dataspace.CartesianDataSpace method
get is a built-in method % matlab.graphics.axis.colorspace.ColorSpace method
get is a built-in method % matlab.graphics.axis.dataspace.DataSpace method
get is a built-in method % matlab.graphics.axis.decorator.DecorationContainer method
get is a built-in method % matlab.graphics.axis.colorspace.MapColorSpace method
get is a built-in method % matlab.graphics.axis.decorator.NumericRuler method
get is a built-in method % matlab.graphics.axis.PlotTarget method
get is a built-in method % matlab.graphics.axis.PlotTargetManager method
get is a built-in method % matlab.graphics.axis.decorator.Ruler method
get is a built-in method % matlab.graphics.axis.camera.Camera method
get is a built-in method % matlab.graphics.axis.camera.Camera3D method
get is a built-in method % matlab.graphics.mixin.AxesParentable method
get is a built-in method % matlab.graphics.mixin.Background method
get is a built-in method % matlab.graphics.mixin.HintConsumer method
get is a built-in method % matlab.graphics.mixin.LegendTarget method
get is a built-in method % matlab.graphics.mixin.UIParentable method
get is a built-in method % matlab.graphics.primitive.world.ClipNode method
get is a built-in method % matlab.graphics.primitive.world.Geometry method
get is a built-in method % matlab.graphics.primitive.world.LightSource method
get is a built-in method % matlab.graphics.primitive.world.LineStrip method
get is a built-in method % matlab.graphics.primitive.world.PrimitiveBase method
get is a built-in method % matlab.graphics.primitive.world.Quadrilateral method
get is a built-in method % matlab.graphics.primitive.world.Text method
get is a built-in method % matlab.graphics.primitive.world.Group method
get is a built-in method % matlab.graphics.primitive.world.SceneNode method
get is a built-in method % matlab.graphics.primitive.canvas.CanvasFactory method
get is a built-in method % matlab.graphics.primitive.canvas.Canvas method
get is a built-in method % javahandle.com.mathworks.hg.peer.HG2FigurePeer method
get is a built-in method % javahandle.com.mathworks.hg.peer.ToolbarPeer method
get is a built-in method % javahandle.com.mathworks.hg.peer.ToolPushButtonPeer method
get is a built-in method % javahandle.com.mathworks.hg.peer.ToolToggleButtonPeer method
get is a built-in method % javahandle.com.mathworks.hg.peer.ToggleSplitButtonPeer method
get is a built-in method % javahandle.com.mathworks.hg.peer.MenuPeer method
get is a built-in method % schema.class method
get is a Java method % com.mathworks.product.util.ProductIdentifier method
get is a built-in method % schema.method method
/opt/MATLAB/R2018a/toolbox/matlab/randfun/@RandStream/get.m % RandStream method
/opt/MATLAB/R2018a/toolbox/matlab/winfun/@COM/get.m % COM method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@figobj/get.m % figobj method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@arrowline/get.m % arrowline method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@scribehgobj/get.m % scribehgobj method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@axischild/get.m % axischild method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@hgbin/get.m % hgbin method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@scribehandle/get.m % scribehandle method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@axisobj/get.m % axisobj method
/opt/MATLAB/R2018a/toolbox/matlab/graph2d/@axistext/get.m % axistext method
/opt/MATLAB/R2018a/toolbox/simulink/simulink/frameedit/@cellline/get.m % cellline method
/opt/MATLAB/R2018a/toolbox/simulink/simulink/frameedit/@celltext/get.m % celltext method
/opt/MATLAB/R2018a/toolbox/simulink/simulink/frameedit/@framerect/get.m % framerect method
/opt/MATLAB/R2018a/toolbox/instrument/instrument/@icgroup/get.m % icgroup method
/opt/MATLAB/R2018a/toolbox/instrument/instrument/@icdevice/get.m % icdevice method
/opt/MATLAB/R2018a/toolbox/instrument/instrument/@iviconfigurationstore/get.m % iviconfigurationstore method
/opt/MATLAB/R2018a/toolbox/shared/instrument/@instrument/get.m % instrument method
/opt/MATLAB/R2018a/toolbox/datafeed/datafeed/@fred/get.m % fred method
/opt/MATLAB/R2018a/toolbox/datafeed/datafeed/@reuters/get.m % reuters method
/opt/MATLAB/R2018a/toolbox/datafeed/datafeed/@rdth/get.m % rdth method
/opt/MATLAB/R2018a/toolbox/datafeed/datafeed/@datastream/get.m % datastream method
/opt/MATLAB/R2018a/toolbox/datafeed/datafeed/@factset/get.m % factset method
/opt/MATLAB/R2018a/toolbox/datafeed/datafeed/@kx/get.m % kx method
/opt/MATLAB/R2018a/toolbox/bioinfo/bioinfo/@phytree/get.m % phytree method
/opt/MATLAB/R2018a/toolbox/bioinfo/bioinfo/@BioMap/get.m % BioMap method
/opt/MATLAB/R2018a/toolbox/shared/controllib/engine/@InputOutputModel/get.m % InputOutputModel method
/opt/MATLAB/R2018a/toolbox/wavelet/wavelet/@laurpoly/get.m % laurpoly method
/opt/MATLAB/R2018a/toolbox/wavelet/wavelet/@wtbo/get.m % wtbo method
/opt/MATLAB/R2018a/toolbox/wavelet/wavelet/@wdectree/get.m % wdectree method
/opt/MATLAB/R2018a/toolbox/wavelet/wavelet/@wptree/get.m % wptree method
/opt/MATLAB/R2018a/toolbox/wavelet/wavelet/@ntree/get.m % ntree method
/opt/MATLAB/R2018a/toolbox/wavelet/wavelet/@dtree/get.m % dtree method
/opt/MATLAB/R2018a/toolbox/wavelet/wmultisig1d/@wpartobj/get.m % wpartobj method
/opt/MATLAB/R2018a/toolbox/matlab/serial/@serial/get.m % serial method
/opt/MATLAB/R2018a/toolbox/shared/statslib/@dataset/get.m % dataset method
/opt/MATLAB/R2018a/toolbox/signal/sptoolgui/@fdmeas/get.m % fdmeas method
/opt/MATLAB/R2018a/toolbox/signal/sptoolgui/@fdline/get.m % fdline method
/opt/MATLAB/R2018a/toolbox/signal/sptoolgui/@fdax/get.m % fdax method
/opt/MATLAB/R2018a/toolbox/signal/sptoolgui/@fdspec/get.m % fdspec method
/opt/MATLAB/R2018a/toolbox/matlab/timeseries/@timeseries/get.m % timeseries method
/opt/MATLAB/R2018a/toolbox/matlab/timeseries/@tscollection/get.m % tscollection method
/opt/MATLAB/R2018a/toolbox/mpc/mpc/@mpc/get.m % mpc method
/opt/MATLAB/R2018a/toolbox/mpc/mpc/@mpcmoveopt/get.m % mpcmoveopt method
/opt/MATLAB/R2018a/toolbox/mpc/mpc/@mpcstate/get.m % mpcstate method
/opt/MATLAB/R2018a/toolbox/mpc/mpc/@mpcsimopt/get.m % mpcsimopt method
/opt/MATLAB/R2018a/toolbox/shared/slcontrollib/@opcond/get.m % opcond method
/opt/MATLAB/R2018a/toolbox/wavelet/wavedemo/@wvtree/get.m % wvtree method
/opt/MATLAB/R2018a/toolbox/sl3d/sl3d/@vrfigure/get.m % vrfigure method
/opt/MATLAB/R2018a/toolbox/sl3d/sl3d/@vrworld/get.m % vrworld method
/opt/MATLAB/R2018a/toolbox/sl3d/sl3d/@vrnode/get.m % vrnode method
/opt/MATLAB/R2018a/toolbox/imaq/imaq/@imaqdevice/get.m % imaqdevice method
/opt/MATLAB/R2018a/toolbox/imaq/imaq/@imaqchild/get.m % imaqchild method
/opt/MATLAB/R2018a/toolbox/ident/ident/@iddata/get.m % iddata method
/opt/MATLAB/R2018a/toolbox/ident/nlident/@customreg/get.m % customreg method
/opt/MATLAB/R2018a/toolbox/ident/nlident/@idnlfun/get.m % idnlfun method
/opt/MATLAB/R2018a/toolbox/robust/rctobsolete/robust/@gsref/get.m % gsref method
>>
Alessandro Cuttin
2018 年 10 月 9 日
In response to @Jan
>> dbstop if warning
>> hold on
Warning: The Position specified is invalid
> In hold (line 37)
Warning from hold (line 37)
ax = gca;
K>>
Rafaelles
2019 年 1 月 4 日
編集済み: Rafaelles
2019 年 1 月 4 日
I got the exactly same error and displayed messages as Alessandro today after installing Matlab r2018a in Fedora 29 os. Is there any solution or idea of what it might be happening?
EDIT: Actually it is a Virtual Machine, installing Matlab in Fedora has always several surprises, so I test in a VM before any change in my personal OS. I'm actually thinking about upgrading from Fedora 28 to 29, so I carried out this test and got the same issue as Alessadro. In my real machine with Fedora 28, Matlab works just fine.
参考
カテゴリ
Help Center および File Exchange で Graphics Object Programming についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!エラーが発生しました
ページに変更が加えられたため、アクションを完了できません。ページを再度読み込み、更新された状態を確認してください。
Web サイトの選択
Web サイトを選択すると、翻訳されたコンテンツにアクセスし、地域のイベントやサービスを確認できます。現在の位置情報に基づき、次のサイトの選択を推奨します:
また、以下のリストから Web サイトを選択することもできます。
最適なサイトパフォーマンスの取得方法
中国のサイト (中国語または英語) を選択することで、最適なサイトパフォーマンスが得られます。その他の国の MathWorks のサイトは、お客様の地域からのアクセスが最適化されていません。
南北アメリカ
- América Latina (Español)
- Canada (English)
- United States (English)
ヨーロッパ
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
アジア太平洋地域
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)