Challenge

Project 1 - Data Handling and Interpolation

data_set=xlsread('VI.xlsx');
x=[-17.3:0.1:0.9];
voltage=data_set(:,1);
current=data_set(:,2);
%doing interpolation linearly.
interp_current=interp1(voltage,current,x,'linear');
%plotting interpolated data.
plot(x,interp_current);grid on;
xlabel('voltage');
ylabel('current');
title('voltage vs current');
fileID = fopen('interpolated_data.txt', 'w');
fprintf(fileID, 'Voltage\t\t Current\n');
d = [x; interp_current];
fprintf(fileID, '%.2f\t\t %.3f\n', d);
fclose(fileID);
Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.