I have a dataset that I want to build in MATLAB, the problem is that this dataset is negative. I want to plot it along the Y axis as if it were positive, so the graph remains in the first quadrant, and I also want the values to display as negative.
I obviously tried:
plot(x,-y);
But this does not work, because it displays the first quadrant, but the values are converted to positive.
Any help on how to do this? I was looking for documentation and forums, and I could not find it.
source
share