MATLAB errorbar colors don't match plot

1 回表示 (過去 30 日間)
Patricia
Patricia 2016 年 2 月 9 日
コメント済み: Patricia 2016 年 3 月 14 日
Hi everyone,
I am using MATLAB R2015b, and plotting with the same errorbar function I have used for many years. Suddenly, the errorbars on my plot are all different colors!
If I plot:
errorbar(1:1:10,1:1:10,2*(ones(1,10)),'.r')
I should have red datapoints and red errorbars, correct? Instead I see...
Where the colors on the errorbars vary from green in the lower left, black in the middle, red in the upper right. I can't figure out where this is coming from. Any thoughts?
  3 件のコメント
Joseph Cheng
Joseph Cheng 2016 年 2 月 10 日
編集済み: Joseph Cheng 2016 年 2 月 10 日
odd... just copying and pasting your example shows up as all red for me. Is there anything else being plotted? or maybe closing all figures, or specifying a new figure would help? I can't think of a reason but maybe a setting was left over in an open plot that this one is keeping instead of clearing the figure/axes before it plots the errorbars?
Eli
Eli 2016 年 3 月 13 日
編集済み: Eli 2016 年 3 月 13 日
I'm having the exact same issue. Similar to you, my error bar color seems to change over the course of the plot, and it's not the same as the main plot color. If I generate an errorbar plot in MATLAB 2010a and then open the .fig file in 2015b, the same issue arises.
Applying the patch Walter Roberson linked to does not seem to fix the problem.

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

採用された回答

Eli
Eli 2016 年 3 月 14 日
I filed a bug report, and got a fix! Just run the command
opengl software
and then try plotting again. It should look correct.
  1 件のコメント
Patricia
Patricia 2016 年 3 月 14 日
That fixed it! Eli- you rule!!

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeErrorbars についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by