MATLAB Answers

processing of satellite data

3 views (last 30 days)
I have some satellite data. I need one particular variable from all this data. But the problem is, that these data are no same dimensional. Let me explain a little bit more. I have daily data for 2years, when I looked into data from first 5 files were 215x3245. But the sixth file has a dimension of 215x3246. This thing happened many time. Maximum dimension was 215x4174. So i can not process the data for delhi region. How can I proceed in this situation. The file size is big, so I could not share the files here. Thak you.
  3 Comments
SWARNENDU PAL
SWARNENDU PAL on 14 Aug 2021
Yes sir, i have those locations. But suppose for one month data, I have 16 data where the data dimension is 215x3245, for 10data the dimension is 215x3246 and rest have dimension of 215x4174. Now, I can use inpolygon for a single data and can plot over Delhi region. But I need to do average for all those data for get monthly average. I got one solution, that was using the griddata function for make the dimension. But in this case the resolutions become more finer, but I dont want to do that. without changing the the resolution how can I proceed. If you want I can share two files of different dimension via gmail or other cloud platform. thank you.

Sign in to comment.

Accepted Answer

Walter Roberson
Walter Roberson on 14 Aug 2021
If the additional data represents reading being taken at higher resolution, rather than extra readings that can be discarded, then you have three choices:
  1. You can regrid. That could be by using griddata() or it could be by using interp2();
  2. You can try to find a function that explains all of the readings. I do not mean a piecewise continuous function; I do not mean fitting a model to the data. I mean a theoretical function based upon external parameters. For example, if you could find that the readings were explained by distance from the Sun and axel tilt and latitude and longitude and a single number representing the intensity of solar flares -- mathematical formulas in which the satellite readings just confirm the formulas. You would never be able to come up with such a thing if the satellite images are rainfall readings for example. Formula in hand, you would discard the readings in the files and just apply the formula at the sets of locations, no regridding needed because the information in the files would be ignored except perhaps datetime.
  3. You can find all of the positions that match exactly in all of the files (to within round-off error), and use only those, and set the rest of the positions to NaN. For example if one of the files had 1, 3/2, 2, 5/2, 3, and the other had 1, 4/3, 5/3, 2, 7/3, 8/3, 3, then you would see the matching 1, 2, 3 and populate there, and set everything else to nan. No regridding, no interpolation. And if one of the datasets happens to be locations 1:1:10 and the other one happens to be 1.001:1:10.001 then you just throw away all of that data because nothing matches.
In practice, regridding is likely to be your only viable strategy.
Remember, you can find all of the unique locations over all of the files, and take all of those together and regrid to that union of all of the locations: when you do that, then every exact data is used (and each dataset gets extended extrapolation to the additional points not explicitly recorded for it.) regridding does not have to mean that you discard data or merge several pieces of data together. However... this approach is likely to end up with irregularly spaced locations, and that makes statistical area calculations difficult...

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by