フィルターのクリア

Plotting negative and positive values with different colors in a graph

33 ビュー (過去 30 日間)
Chandrika Avvaru
Chandrika Avvaru 2018 年 5 月 31 日
コメント済み: Shrestha Kumar 2018 年 5 月 31 日
I have a correlation coefficients matrix consisting of positive and negative values and I need to plot the graph for that matrix separating positive and negative values with different colors to distinguish them.

回答 (1 件)

Shrestha Kumar
Shrestha Kumar 2018 年 5 月 31 日
Hi,
You can find your answer here-
https://in.mathworks.com/matlabcentral/answers/285397-plotting-negative-values-with-blue-and-positive-values-with-red
  2 件のコメント
Chandrika Avvaru
Chandrika Avvaru 2018 年 5 月 31 日
Hi, I checked the code but that doesn't work for me.My matrix is 11*11.
Shrestha Kumar
Shrestha Kumar 2018 年 5 月 31 日
Ok, so what you can do is that you can create two separate linear arrays of positive and negative numbers from the matrix and then plot each array with different color.

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

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by