Making an array for a density plot

2 次查看(过去 30 天)
Joydeb Saha
Joydeb Saha 2020-4-27
I have 619209x1 double Latitude and 619209x1 double Longitude. The maximum lat value is 83.40 and minimum lat value is -79.83. similarly max long value is 179.99 and min long vaue is -179.99. Depending on their max min value I have made a dummy matrix of 155x360 double. Now, I need a code where , say lat value is 2.25 and long value is 2.75, a loop will add (place) 1 at the 2x2 cell. similarly say lat value is 2.75 and lng value is 2.88 then at the 2x2 cell there will be addding up, i.e, 1+1 =2 . This thing will continue for each of the numbers in the lat and long depending on the first digit before the decimal. e.g, lat = 85.44 and lon = 85.14, there will be +1 in the 88th cell. This is required for a density plot.

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Annotations 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by