Hi,
You can fill in the missing data by using the "fillmissing" function with the 'linear' method to interpolate missing values. For this, you need to identify the rows with missing values and generate a new time vector that fills in the gaps with 7-minute intervals. Finally, interpolate to fill in the missing values for the parameter column.
Refer to an example pseudo-code for better understanding:
% Load your data
data = readtable('your_data_file.csv');
% Convert 'Time' to datetime if it's not already
data.Time = datetime(data.Time, 'InputFormat', 'yyyy-MM-dd HH:mm:ss');
% Identify the time range
startTime = min(data.Time);
endTime = max(data.Time);
% Create a new time vector with 7-minute intervals
newTime = (startTime:minutes(7):endTime)';
% Merge the new time vector with the existing data
newData = table(newTime, 'VariableNames', {'Time'});
mergedData = outerjoin(newData, data, 'MergeKeys', true);
% Interpolate missing values in 'Parameter'
mergedData.Parameter = fillmissing(mergedData.Parameter, 'linear');
% Display the filled data
disp(mergedData);
% Optionally, save the filled data to a new file
writetable(mergedData, 'filled_data.csv');
For more information on the "fillmissing" function, refer to the below documentation: