R=[2.4 5.6 10 51 100];
I1=[在此填入5个电流值,下同]; %建议使用自己测得的数据
V1=[在此填入5个电压值,下同];
I2=[];
V2=[];
I3=[];
V3=[];
I4=[];
V4=[];
subplot(221);
set(0, 'defaultaxeslinestyleorder','-|--')
set(0, 'defaultaxescolororder', [ 0 ,0,0 ] )
[haxes,hline1,hline2]=plotyy(R,I1,R,V1,'plot','plot');
legend('I1','V1', 0)
set (hline2, 'LineStyle',':')
axes(haxes(1))
ylabel('I/(uA)');
axes(haxes(2))
ylabel('V/(mV)');
xlabel('R/(千欧姆)');
title('光照度为50Lx');
subplot(222);
[haxes,hline3,hline4]=plotyy(R,I2,R,V2,'plot','plot');
legend('I2','V2', 0)
set (hline4, 'LineStyle','