Working with Mapping Toolbox

조회 수: 1 (최근 30일)
Nadia Ben Hadid
Nadia Ben Hadid 2019년 3월 24일
Hi everyone,
I'm a PhD student from France and a new user of matlab.
I work on a specific lagoon in Tunisia, and to be more precise I want to numerically simulate the tidal current in the lagoon using Mapping Toolbox. Do you think it's possible ?
First of all I tried to download shapefiles of Tunisia to work with but the result is not very satisfying.
Here is the code I used:
% Define a map area of interest
latlim=[36.7, 36.9];
lonlim=[10.1, 10.4];
%Import multiple shapefile with vector data
tun_water=shaperead('TUN_water_areas_dcw.shp','UseGeoCoords',true,...
'BoundingBox',[lonlim(1) latlim(1); lonlim(2) latlim(2)]);
tun_lines=shaperead('TUN_water_lines_dcw.shp','UseGeoCoords',true,...
'BoundingBox',[lonlim(1) latlim(1); lonlim(2) latlim(2)]);
tun_rails=shaperead('TUN_rails.shp','UseGeoCoords',true,...
'BoundingBox',[lonlim(1) latlim(1); lonlim(2) latlim(2)]);
tun_roads=shaperead('TUN_roads.shp','UseGeoCoords',true,...
'BoundingBox',[lonlim(1) latlim(1); lonlim(2) latlim(2)]);
% Visualizating the data
figure;
worldmap(latlim,lonlim);
title('North lagoon of Tunis');
%Plot shorelines and color appropriately
geoshow(tun_lines,'color','black');
geoshow(tun_rails,'color','black','linestyle','--');
geoshow(tun_water);
geoshow(tun_roads,'color','red');
%%
% Customize the plot by inserting annotations, rulers, and a north arrow
% Insert scale ruler and North arrow
scaleruler('units','mi','YLoc',.5,'XLoc',-4.5e-3);
northarrow('latitude',36.5,'longitude',10.2);
I coud generate something like this, which is useless
carte NON.jpg
Can anyone help me to display the correct format of the lagoon so I can go forward in my work ?
Also, I think for my work, a code like
createMap(latlim,lonlim,'BathymetryData',noaashore)
doesn't work for me.
So can anyone tell me how I have to reformate my own bathymetry data, so I can work with it.
Thanks.
Nadia.

답변 (0개)

Community Treasure Hunt

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

Start Hunting!

Translated by