Generating Geographical matrix using Loop
이전 댓글 표시
I am trying to generate a 2D matrix for the geographical Longitude and Latitude, for the ranges below:
Φ = [0,Δφ,2Δφ, ..., 179Δφ] Θ = [0,Δθ,2Δθ, ..., 287Δθ] . I tried this
long=linspace(0,360,288); lat=linspace(0,180,180); res=zeros(288,180); for i=0:1.25:length(long) for lat=0:1:length(long) res(long,lat)=[long lat]; end end but I got this error
Subscript indices must either be real positive integers or logicals.
Error in odayalbedo (line 12) res(long,lat)=[long lat];
Any suggestions??? Thanks in advance
댓글 수: 1
Oday Shahadh
2017년 2월 6일
편집: KSSV
2017년 2월 6일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Coordinate Reference Systems에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!