Matlab plotting errors when trying to compute integral and double integral

My Code

M=dlmread('C:\Users\distanceY.data','\t');

xaccel=M(:,5);

time = 0:0.05:781.45;

figure

plot(time,xaccel)

title('Acceleration')

xlabel('Time')

Z=cumtrapz(time,xaccel);

figure

plot(time,Z)

title('Velocity')

xlabel('Time')

W=cumtrapz(time,Z);

figure

plot(time, W)

title('Distance')

xlabel('Time')

It gives me errors

Error using plot Vectors must be the same length.

Error in Graph2 (line 5) plot(time,xaccel)