Missing value: Adding new row of NaN in a time series. Need some twist in code
Ältere Kommentare anzeigen
Dear all,
I want to create some new rows of NaN (lets say NaN(1,:,:)) in gridded time series (e.g., A_matrix (200,40,50)) to fill up some missing months in between. I have identified the missing months using:
[missingvalues,id] = setdiff(actual_period,data_dates);
where id is the index of missing month OR
[locCol, loc] = ismember(actual_period,data_dates);
where loc is an index of logical values for 0=missing month.
Based on the index values I need to add extra rows (NaNs) to A_matrix so that I can interpolate them.
Kindly help me... Khandu
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Resizing and Reshaping Matrices finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!