how to plot x axis with ratio unit instead of proportional unit

1 次查看(过去 30 天)
I'm doing some research about electrodes, and I want to show the relationship between electrode contact impedance and measured voltage, with contact impedance as x axis and measured voltage as y axis.
My problem is the data of contact impedance is in ratio and not propotional, and when plotting it can only shows a spicific region and not all of the contact impedance data.
My contact impedance data points are 1000, 1, 10^-3, 10^-6, 10^-9, and when i plot it only shows region between 1 and 1000 so the measured voltage below impedance=1 are all squeezed to the left. Is there any way that i can expand the left side of the x axis and make it look like a propotional x axis so the measured V can be clearly seen, and their corrisponding impedance?

采纳的回答

Star Strider
Star Strider 2021-7-15
I am not certain that I understand the problem. However when you mention ‘squeezed to the left’, that could be correctged by using a semilogx (or loglog) plot.
Consider —
x = [1E-9 1E-6 1E-3 1 1E+3];
y = x.^2;
figure
subplot(3,1,1)
plot(x, y, 'p-', 'LineWidth',2)
grid
title('linear')
subplot(3,1,2)
semilogx(x, y, 'p-', 'LineWidth',2)
grid
title('semilogx')
subplot(3,1,3)
loglog(x, y, 'p-', 'LineWidth',2)
grid
title('loglog')
.

更多回答(1 个)

KSSV
KSSV 2021-7-15
You can plot log of the value. Read about semilog.

类别

Help CenterFile Exchange 中查找有关 MATLAB 的更多信息

标签

产品


版本

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by