how to add missing months in loop?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
I have a monthly soil moisture data of 10 year in hdf format. The data file contains 105 hdf file, 15 months are missing. The dimension of matrix is 180*360 now I want to create this matrix in 180*360*120. How could I add missing months in a loop.
2 Commenti
Risposte (1)
Stephen23
il 18 Feb 2015
Modificato: Stephen23
il 18 Feb 2015
Use one of the interpolation tools , filling in missing data is exactly what they can do. Which tool you select depends on the shape of your data, and your own requirements for the "filling" in of the data. For a start, try interp1 .
Note that you can interpolate all of the data at once, without loops, by using the matrix input of most of these functions, eg for interp1: If you have multiple sets of data that are sampled at the same point coordinates, then you can pass v as an array. Each column of array v contains a different set of 1-D sample values.
Note that interpolation does not require any loops, even though you put this in the question title.
0 Commenti
Vedere anche
Categorie
Scopri di più su Genomics and Next Generation Sequencing in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!