<jupyter_start><jupyter_text>Exploring different Coastline options in MagicsThis notebook will help you discover lots of posibilities for designing background of your maps in Magics.From your workstation:  load magics   module swap(or load) Magics/new  jupyter notebook  load this notebook **mcoast** controls background of our maps. Here you can set things like colours of land and sea, coastline resolution and colour, and also grid, rivers, boarders, cities etc.  List of all **mcoast** parameters you can find [here](https://confluence.ecmwf.int/display/MAGP/Coastlines "Coastlines parameters")  Import Magics and define non coastline paramtersFor start we will define some none coastline parameters, which we will not change later.<jupyter_code>import Magics.macro as magics

projection = magics.mmap(
    subpage_map_library_area = "on",
    subpage_map_area_name = 'central_europe'
)<jupyter_output><empty_output><jupyter_text>As with all Magics functions, default is something you can start with. But if you don't like it, *everything* can be changed<jupyter_code>coast = magics.mcoast()

magics.plot(projection, coast)<jupyter_output><empty_output><jupyter_text>High resolution coastline and dash gridlinesIn Magics we can fully control how land and sea look like.  Coastline resolution can be 'low', 'medium' or 'high', or if you want to leave Magics to decide, you can set it as 'automatic'.  Land and sea can be shaded or not, and you can set the colour.  You can choose to have gridlines or not, their frequency, style, colour, thickness, labels...<jupyter_code>coast = magics.mcoast( 
    map_coastline_style             = "solid",
    map_coastline_colour            = "tan",
    map_coastline_resolution        = "high",
    map_coastline_land_shade        = "on",
    map_coastline_land_shade_colour = "cream",
    map_grid                        = "on",
    map_grid_colour                 = "tan",
    map_grid_latitude_increment     = 5.00,
    map_grid_longitude_increment    = 10.00,
    map_grid_line_style             = "dash",
    map_label                       = "on",
    map_label_colour                = "charcoal",
    map_label_height                = 0.35,
    map_label_latitude_frequency    = 2,
    map_label_longitude_frequency   = 2,
    map_label_blanking              = "off"
    )

magics.plot(projection, coast)<jupyter_output><empty_output><jupyter_text>Administrative boundaries, cities and rivers<jupyter_code>coast = magics.mcoast(
    map_boundaries                               = "on",
    map_boundaries_colour                        = "red",
    map_coastline_resolution                     = "high",
    map_coastline_land_shade_colour              = "cream",
    map_cities                                   = "on",
    map_grid                                     = "off",
    map_coastline_land_shade                     = "on",
    map_coastline_colour                         = "tan",
    map_administrative_boundaries                = "on",
    map_administrative_boundaries_countries_list = ["FRA", "ESP", "GBR"],
    map_administrative_boundaries_colour         = "orange",
    map_rivers                                   = "on"
)

magics.plot(projection, coast)<jupyter_output><empty_output><jupyter_text>Grid lines, boundaries and rivers<jupyter_code>coast = magics.mcoast(
    map_boundaries                  = "on",
    map_boundaries_colour           = "red",
    map_coastline_resolution        = "high",
    map_coastline_colour            = "tan",
    map_coastline_land_shade        = "on",    
    map_coastline_land_shade_colour = "cream",
    map_grid                        = "on",
    map_grid_line_style             = "dot",
    map_grid_colour                 = "tan",
    map_grid_latitude_increment     = 2.00,
    map_grid_longitude_increment    = 2.00,   
    map_grid_latitude_reference     = 0.00,
    map_rivers                      = "on"
)

magics.plot(projection, coast)<jupyter_output><empty_output><jupyter_text>Sea, lakes and rivers<jupyter_code>coast = magics.mcoast(
    map_coastline_sea_shade_colour = "sky",
    map_coastline_resolution       = "high",
    map_rivers_colour              = "sky",
    map_grid                       = "off",
    map_coastline_land_shade       = "off",
    map_coastline_colour           = "sky",
    map_coastline_sea_shade        = "on",
    map_rivers                     = "on")


magics.plot(projection, coast)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.08050089445438283, 'fraction_numerical': 0.004695885509838999, 'mean_word_length': 2.4674418604651165, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 25, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '6', 'dir': 'jupyter-structured-clean-dedup', 'id': '11366', 'license': 'Apache-2.0', 'n_tokens_mistral': 1426, 'n_tokens_neox': 1349, 'n_words': 319, 'path': 'visualisation/tutorials/Coastlines.ipynb', 'repo_name': 'mrocklin/notebook-examples', 'size': '4472'}