MATLAB Answers


Plotting negative and positive values with different colors in a graph

Asked by Chandrika Avvaru on 31 May 2018
Latest activity Commented on by Shrestha Kumar on 31 May 2018
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.


Sign in to comment.


1 Answer

Answer by Shrestha Kumar on 31 May 2018

You can find your answer here-


Hi, I checked the code but that doesn't work for me.My matrix is 11*11.
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.

Sign in to comment.