I'm trying to plot a set of data. This is my code:
clcclearclose allstat = importdata("static pressure.txt");dir = importdata("direction.txt");tot = importdata("total pressure.txt");cp_cfd = (stat-tot)/(0.5*0.8*36.3^2);plot(dir/0.1524,-cp_cfd,'r','.');
But, since direction.txt is not ordered for smallest to largest, the plot comes out like this (the plot function doesn't automatically order it):
I would like it to look like this (this is a scatter plot and I drew in a line in paint to show what I would like it to look like):
How would I do this?
Best Answer