Why can't I place a data cursor below a certain value on my plot?
Ältere Kommentare anzeigen
I'm pretty new to Matlab, and struggling with something I don't quite understand. Basically, I'm using the code below to set up a function handle, substitute a value for one of the symbolic variables, then plot that function over the range 1x10^-7 to 1.
However, this gave me some issues and a plot that didn't look correct, so I bumped up the MeshDensity to 100,000 so that there would be more data points. I'm also using a logarithmic scale for the horizontal axis.
The issue is, when I try to place a cursor anywhere below x ~= 10^-2, the cursor shows up at x ~= 10^-2. At this point, I can drag it to the right to check larger points, but I can't drag it further left than x ~= 10^-2. Even when I set my range to [1e-7 1e-5] and plot, clicking to set a data cursor doesn't produce a visible cursor anywhere on the plot. The only thing that allows me to move the cursor along the whole range of my plot is not setting the x-axis to a log scale. Any ideas? Thanks in advance!
Edit: Something else I just noticed: the effective lower limit of my data cursor is at least somewhat tied to the size of the window containing my figure. The limit of x ~= 1e-2 decreases to 0.5e-2 when I decrease the window size of my figure. This remains the limit no matter how small I make the window though, and the limit of x ~= 1e-2 remains no matter how big I make the window.
syms T P lambda
mfp_eqn = @(P) k*T/(sqrt(2)*pi*d^2*P);
mfp_eqn = subs(mfp_eqn, T, 300);
fp = fplot(mfp_eqn, [1e-7, 1]);
fp.MeshDensity = 100000; % sets minimum number of data points
ylim([0 1e5]); % expands limits of vertical axis
set(gca,'xscale','log') % set pressure scale to logarithmic
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Polar Plots finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!