Graphic Design Archives - Matthew Gove Blog https://blog.matthewgove.com/category/matthew-gove-web-development/graphic-design/ Travel the World through Maps, Data, and Photography Mon, 30 May 2022 21:30:58 +0000 en-US hourly 1 https://wordpress.org/?v=6.1.5 https://blog.matthewgove.com/wp-content/uploads/2021/03/cropped-android-chrome-512x512-1-32x32.png Graphic Design Archives - Matthew Gove Blog https://blog.matthewgove.com/category/matthew-gove-web-development/graphic-design/ 32 32 How to Create a Custom Map in Adobe Illustrator https://blog.matthewgove.com/2022/06/10/how-to-create-a-custom-map-in-adobe-illustrator/ Fri, 10 Jun 2022 15:00:00 +0000 https://blog.matthewgove.com/?p=4781 Custom, branded maps are one of the best ways you can stand out from your competition, especially in the world of travel and content creation. With so many people, groups, and organizations still relying on products like Google Maps, you’ll not only stand out from the crowd, but also come […]

The post How to Create a Custom Map in Adobe Illustrator appeared first on Matthew Gove Blog.

]]>
Custom, branded maps are one of the best ways you can stand out from your competition, especially in the world of travel and content creation. With so many people, groups, and organizations still relying on products like Google Maps, you’ll not only stand out from the crowd, but also come across as way more professional. And Adobe Illustrator makes it incredibly easy to create a custom map for your next video, presentation, or any other type of content.

Last time, you learned how to import GIS shapefiles into Adobe Illustrator. Today, you’re going to use those imported shapefiles to create a custom map in Adobe Illustrator.

Where We Left Off Last Time: Importing GIS Shapefiles into Adobe Illustrator

In the previous tutorial, we began the process of creating custom maps in Adobe Illustrator. That tutorial focused on importing GIS shapefiles into Adobe Illustrator, which consisted of several steps.

  1. Load several shapefiles into QGIS to create vector outlines
  2. Export those vector outlines from QGIS into SVG Format
  3. Import the SVG Map into Adobe Illustrator
  4. Scale and Position the Map to Fill our Illustrator workspace

What We’re Going to Learn Today: Finishing Your Custom Map in Adobe Illustrator

Today, we’re going to finish the process of creating a custom map in Adobe Illustrator. In this tutorial, you’ll learn how to do the following:

  • Extract parts of the vector and sort them into layers
  • Add titles, labels, and the background imagery
  • Set up your map for animation

At the end of the day, you’ll wind up with a beautiful final map product that looks like this:

1. Extract Your Custom Map Features from the SVG File in Adobe Illustrator

To make it easier to manage your custom map assets in Adobe Illustrator, put each feature (or group of features) into their own layers. We covered this briefly in the previous tutorial, but I want to go over it in much more detail. First, let’s recall where we left off. We had just imported the SVG (vector image) file into Adobe Illustrator using File > Place.

Shapefile Features Loaded into Adobe Illustrator from an SVG Vector Image File

Before we do anything in Illustrator, make a list of the features you will be extracting from the SVG file. For the Utah National Parks, we want to extract the following:

  • The Utah State Boundary
  • Zion National Park Outline
  • Bryce Canyon National Park Outline
  • Capitol Reef National Park Outline
  • Canyonlands National Park Outline
  • Arches National Park Outline

If it helps, you can also make a list of everything you want to exclude from the final map. For our map of the Utah National Parks, we only need to exclude the rectangle that bounds the SVG image, which is outlined in blue in the above screenshot. Don’t worry about colors at this point. We’ll address them shortly.

Scale and Position Your Custom Map in Adobe Illustrator Before Extracting Any Features

Before you extract any features from the imported SVG file, I highly recommend that you scale your custom map and move it into its final position on the Adobe Illustrator artboard. You can always make minor to its position and scale as you go. However, it’s much easier to do any major moving and scaling while it’s still just a single entity.

To scale the SVG file in Illustrator, simply grab any of the anchor points on the corner or side of the SVG file and drag it to its desired size. To prevent image distortion, hold the Shift key down as you scale it, which maintains the original aspect ratio.

The green rectangles in Illustrator mark the boundaries of your artboard, so scale it to fill as much of the artboard as possible. If you need to scale the SVG beyond the boundaries of the Adobe Illustrator, that’s perfectly fine. Illustrator will crop everything to fit the artboard when you go to export it.

Additionally, make sure that you leave room for any titles, subtitles, and labels you’ll be adding to the map later. You should also center the map horizontally in the frame. Your scaled and centered custom map of Utah should look something like this in Adobe Illustrator.

Scaled and Centered Shapefile/SVG Features in Adobe Illustrator

Extract Each Feature of Your Custom Map into Its Own Layer in Adobe Illustrator

On the initial extraction, you should put each feature into its own layer in Illustrator. We do this for two reasons.

  1. It best sets the map up for animation
  2. It’s much easier to merge multiple layers into one than it is to separate one layer in several.

To begin your feature extraction, first open the Layers panel. Click on the carat to reveal the components of the SVG layer.

Expanded Layers Circled in Red on the Right Hand Side of the Main Adobe Illustrator Window

Despite there being so many components, the features you want to extract are only going to be in a small subset of those components. The easiest way to find your map features is to click on the eyeball next to each component in the layers panel. If your feature disappears from the map, that’s the component you need to extract.

To extract the component you’ve identified, create a new layer to put it in. Don’t worry about the order of layers for now. The new layer button is in the bottom right corner of the main Adobe Illustrator window. Give it an easily identifiable name, such as “Zion Boundary” or “Canyonlands Outline”.

The New Layer Button in Adobe Illustrator

Click and drag the component from the original SVG file to the layer you just created. You should see the feature now listed under the new layer. Do note that your feature may be divided into several components in the SVG layer. In that case, drag each component of your feature to your new layer.

To confirm everything copied correctly, click the eyeball to show and hide your new layer. Your feature should disappear from and reappear on the map.

Outline of the Utah State Border and Zion National Park Extracted From the SVG File

Finally, repeat the process for each feature you will be putting on your final map. Once everything is extracted into their own layers, you can hide or delete the original SVG layer. We will not be using it anymore.

A Note on Dealing with Complex Features

If you have a complex feature you are trying to extract or if two features you want on your map are combined into a single component of the SVG file, you can still extract them. Use Illustrator’s Eraser tool to delete any unwanted parts of the SVG components. You can separate multiple features from a single SVG component with Illustrator’s Direct Selection Tool. Please consult the Adobe Illustrator documentation for more details.

2. Add a Background Image

Next up, we’ll add the background image. In our Utah National Parks map, the background image is of the hoodoos at Bryce Canyon from my trip in 2017. Your background image should be a high enough resolution to fill the artboard of your Adobe Illustrator project. Remember that while Illustrator is a vector editing program, your images still consist of pixels. If you scale them up beyond their full resolution, they will become pixelated and grainy.

Before you add your background image, though, you will need to do a couple things. These are both optional, but I highly recommend doing them.

  1. Crop your image to match the aspect ratio of your artboard in Adobe Illustrator. For videos, that aspect ratio is 16:9. I do this mainly for my own sanity so I don’t accidentally put features outside of the artboard boundaries that will get clipped off.
  2. If you plan to use a background overlay that’s any color other than black or white, make your image black and white. Colored overlays can do wonky things to the colors of your image, often with undesirable results. If you’re using your own branding, black and white images help ensure that the map stays the recognizable colors of your brand.

Use Illustrator’s File > Place function to embed your background image into Illustrator. The features you imported in the previous step may disappear from view, but don’t worry. They’re just underneath the image. We’ll correct that shortly. Then, drag each corner of the image to the corners of your artboard to fill it.

Don’t panic if other features disappear when you load the background image. They’re just underneath the picture.

3. Add a Background Overlay

A background overlay is a solid color, semi-transparent overlay that goes on top of your background image. Its primary purpose is to make the content of your map easier to read. Not only does it increase the contrast, but it also makes the background image much more subtle. Remember, you want your viewers’ eyes to be drawn to the content, not to the background image.

Use the slider below to see the difference between having a background overlay vs having nothing. The difference in readability is night and day.

Background Overlay Setup in Adobe Illustrator

You should put the background overlay either in the same layer as your background image or in its own layer. The easiest way to add the background overlay is with Illustrator’s Rectangle Tool.

Location of Illustrator’s Rectangle Tool in the Toolbar

After creating the rectangle in Illustrator, drag the corners so the rectangle fills the artboard.

The Background Overlay will not look terribly exciting when you first load it.

Background Overlay Color and Opacity

Your background overlay should never be anything besides a single color. It will be too distracting otherwise. If you want to use a secondary color, make the text and content of your map that color. Remember, color can be very powerful for invoking emotions in your audience. Use it wisely.

So what color should you make your background overlay? I recommend one of three options.

  1. Your Primary Brand Color
  2. Black
  3. White

Unless you want to put more emphasis on your background image, you should use your primary brand color for the background overlay. For example, Coca-Cola would use red, UPS would brown, and John Deere would use green.

Start with the opacity set at 75 to 85%, and adjust it as needed. You should be able to see your background image through the overlay and be able to immediately recognize what it is. However, you don’t want the background image to distract from the content on your map.

The background image subtly shows through the background overlay that’s set to 80% opacity

Interestingly, you may have a situation where you want to emphasize the background image a little more. It comes up more often than you’d think. I use it on the title screens of pretty much all of my videos.

In that case, you should use a black or white background overlay, and set the opacity to 30 to 50% to start. Like before, you’ll need to adjust it as necessary. I also recommend using a color background photo, because the black or white overlay won’t distort the colors of your image.

Example of a Black Background Overlay Set to 40% Opacity from Our Arches and Canyonlands Video

4. Add Any and All Map Titles, Subtitles, Labels, and Branding

The final elements to add are the title, labels, and branding. Like the background overlay, most of these should go either in the same layer as the background image and/or overlay, or in their own layer. However, there is one distinct exception. All feature labels should go in the same layer as the feature itself, or in their own layer. If you plan to animate the feature labels independently of the features themselves, each label must go in its own layer.

Use the text tool in Adobe Illustrator to add text to your custom map. Set the font to either match your brand fonts, which I highly recommend, or, to an easy-to-read font. The last thing you want is your viewers struggling to read the beautiful map you put such effort into.

Title text and Branding on our Utah National Parks map. We labeled the features, but you can’t see them because they’re still underneath the background image.

5. Arrange the Layers in the Correct Order

Now that we’ve got all of the elements of our map in place, it’s time to put the layers into the correct order so you can see all of your features. If you’re not familiar with the concept of layers, it’s very similar to making a sandwich. For example, the layers of a ham sandwich, from top to bottom, would be something like this:

  • Bread
  • Mayo/Mustard
  • Cheese
  • Veggies
  • Ham
  • Mayo/Mustard
  • Bread

Likewise, we can arrange the layers of our map in a similar order. From top to bottom, the layers of our map are as follows.

  • Features and Feature Labels (unless they overlap, the order of each individual feature layer does not matter)
  • Titles, Subtitles, Labels, and Branding
  • Background Overlay
  • Background Image

To rearrange the order of your custom map layers in Adobe Illustrator, open the Layers panel. Then, all you have to do is click and drag the layers into the correct order. Make sure you don’t accidentally put one layer into another. However, if you do, a Ctrl/Cmd-Z is all it takes to undo your mistake.

Utah National Parks Map with Layers in the Correct Order

6. Set the Colors of Your Custom Map Features in Adobe Illustrator

All right, we’re almost there. All that’s left is to set the colors of our map features. And thankfully, that’s an easy, straightforward task. On the map, hold down the Shift key and click on all of the features you want to color to select them. To set the color, go to the properties tab and set the fill and stroke colors. You can also add opacity to each feature if you wish. On the Utah National Parks map, we left the opacity at 100% for all features.

Utah National Parks map after coloring the parks white and removing the fill from the Utah boundary

Congratulations, you’re all done! You should have a final map that looks similar to the one below.

Conclusion

Creating a custom map in Adobe Illustrator is a fantastic way to increase brand awareness. And now, you’re completely ready to take the next big step into the world of map animation. You’ll learn all about that in the next installment of this series.

Additionally, custom maps are much easier to read and will put you leaps and bounds ahead of your competitors who are still using Google Maps. They’ll also make you look way more professional. Are you ready to get started with your own custom, branded maps? Get in touch with us today and get started with a free info session.

Top Photos: Hoodoos in the Late Afternoon Sun
Bryce Canyon National Park, Utah – May, 2017

The post How to Create a Custom Map in Adobe Illustrator appeared first on Matthew Gove Blog.

]]>
How to Import Shapefiles into Adobe Illustrator https://blog.matthewgove.com/2022/06/03/how-to-import-shapefiles-into-adobe-illustrator/ Fri, 03 Jun 2022 15:00:00 +0000 https://blog.matthewgove.com/?p=4744 GIS software is an incredibly powerful tool for displaying data on a map. However, they have their limits. And content creators often push well beyond those limits. Thankfully, Adobe Illustrator can help fill that void for creators that GIS programs, which are geared towards a much more technical audience, leave […]

The post How to Import Shapefiles into Adobe Illustrator appeared first on Matthew Gove Blog.

]]>
GIS software is an incredibly powerful tool for displaying data on a map. However, they have their limits. And content creators often push well beyond those limits. Thankfully, Adobe Illustrator can help fill that void for creators that GIS programs, which are geared towards a much more technical audience, leave behind. Today, you’re going to learn how to import GIS shapefiles into Adobe Illustrator. Not only will this enhance your professional brand, but also put you leaps and bounds ahead of the crowds that are still using Google Maps.

Which begs the question…why are so many people still using Google Maps screenshots in their videos, presentations, and other content? Yes, Google Maps is an incredible tool, but they were not designed to be used in videos and presentations. Worst of all, they tend to flash on the screen for such a short time that it’s next to impossible to tell where you are, where you’re going, or what you’re doing. In which of the following maps can you locate Utah’s “Big 5” National Parks faster?

Using Branded, Custom Maps Really Makes You Stand Out From the Crowds Still Using Google Maps

Creating custom maps in Adobe Illustrator can fix all of that. Put your own branding and style on the map. Remove everything that’s not relevant to the story you’re trying to tell. Give it a breathtaking design. Make it uniquely you. It’s such an easy way to look very professional and really stand apart from everyone still using Google Maps.

Finally, and best of all, you don’t have to spend a fortune to achieve incredible results with your maps. In this tutorial, the only thing you’ll need to pay for is Adobe Illustrator. Everything else is available free of charge. Let’s go.

What is a Shapefile?

A shapefile is simply a geospatial vector data format. Vector data formats in GIS and mapping applications are incredibly fast and efficient because of their small file size. You can put an enormous amount of data into a pretty small file, which also makes vector data formats ideal for web-based applications.

ESRI originally created the shapefile for its ArcView GIS software back in the early 1990’s. Today, shapefiles are widely used and nearly universally supported throughout the GIS world. However, I do want to point out that despite their widespread use, they are still a proprietary format. As a result, if you prefer open source file formats, I recommend using either GeoJSON or CSV to store your data. Both can be used as vector formats and you can import them into Adobe Illustrator using the same method we’ll use for shapefiles below.

Shapefiles exist for just about every type of feature out there. You can store data as points, lines, or polygons. Indeed, I’ve used them for everything, including severe weather warnings, road trip routes, National Park boundaries, and much more. Because of their widespread availability, both ESRI and government entities (federal, state/province, and local) maintain extensive databases of shapefiles. If you can’t find what you’re looking for there, you should be able to find it with a quick Google search. While this tutorial only uses the geometry of the shapefiles, you can easily add your own data either directly into the shapefile or through region mapping.

Shapefiles of the State of Utah and its “Big 5” National Parks Open in QGIS

Why Import Shapefiles into Adobe Illustrator?

If you’re just looking to plot data on a map, then by all means, a GIS program is the best way to go. However, GIS programs definitely have their limits. That’s where Adobe Illustrator comes in. When you import your shapefiles into Adobe Illustrator, you get much finer control over the final map design and look. The end result is a much more polished and professional-looking map, especially if you’re putting them into videos or presentations.

Furthermore, Adobe Illustrator provides the bridge to animating your maps. If you’re a content creator or giving a presentation, fully animated maps will put you in a class above your competition who are still using screenshots of Google Maps in their videos and presentations. Don’t believe me? Have a look at the maps below. Which one is easier to identify the “Big 5” National Parks in southern Utah?

While GIS software does support the bare basics for animation, you can make far more powerful animations even just using Illustrator itself. However, to unlock its full potential, you’ll need to use something like Adobe After Effects.

Click Play to See an Example of a Custom Map I made in Adobe Illustrator and Animated in After Effects

Unfortunately, animation is a topic for another day. We’ll cover that in a future tutorial. Let’s get back to learning how to import shapefiles into Adobe Illustrator.

1. Download and Install QGIS, a Free GIS Program

As a content creator myself, I know how critical it is to keep the cost of doing business to a minimum. And as a GIS specialist, I also know how expensive some proprietary GIS software can be. As a result, I’ve designed this tutorial so that the only piece of software you need to pay for is Adobe Illustrator.

If you’ve used ESRI’s ArcGIS before, you may be aware that Arc has an “Export to Illustrator” option built into it. That will export your shapefiles directly into a .ai Adobe Illustrator file. However, the desktop version of Arc also costs a bare minimum of $700 per year to use. Instead, we’ll use QGIS for this tutorial. QGIS is open source and, best of all, completely free. And unlike Arc, it runs on MacOS, Windows, and Linux. You can download QGIS here.

2. Prepare Your Shapefiles in QGIS

Before we can import our shapefiles into Adobe Illustrator, we first need to prepare them in QGIS. Using QGIS will ensure that each feature appears on your map in its proper location. You can try to eyeball the correct location once it’s all imported into Illustrator, but trust me, that never ends well.

Create a New Project in QGIS

First, you’ll need to create a new project in QGIS into which you’ll load your shapefiles. You’ll also need to change the default map projection, which will prevent your shapefiles from becoming distorted.

First, open QGIS and select Project > New Project. This will open a blank project. Then, in the bottom right, click on the text that says “EPSG:4326”. QGIS will open a window so you can select a new projection.

In the search bar, search for “Pseudo-Mercator”. You’ll likely see multiple results returned. Select the result labeled “EPSG:3857”.

Click OK to confirm your changes. The text in the bottom right should change from “EPSG:4326” to “EPSG:3857”.

Finally, if you want to include a basemap to confirm your features are both properly projected and in the correct location, double click on the OpenStreetMap option in the browser on the left-hand side of your QGIS dashboard. Please note that you should only use the basemap should a reference and never import it into Adobe Illustrator with the rest of your shapefiles.

Load Your Shapefiles into QGIS

When you prep your shapefiles in QGIS for import into Adobe Illustrator, you can include as many or as few as you want. When you export them to Adobe Illustrator, they’ll all get exported as a single-layer entity, so you don’t need to worry about keeping track of a ton of layers.

Adding shapefiles to your QGIS project is easy.

  1. Select Layer > Add Layer > Add Vector Layer from the top menu. A window will open.
  2. Under the “Source” section, you’ll see an input labeled “Vector Dataset(s)”. Click on the three dots to the right of the text input.
  3. Navigate to the folder with your shapefiles and select all the shapefiles you wish to load into QGIS. You only need to select files with the .shp extension.
  4. Click the “Add” button at the bottom of the window to add them to your QGIS project.
  5. Repeat steps 2-5 until all of your shapefiles are loaded into QGIS.
  6. Close the window.

Once everything is loaded into QGIS, make sure that all of the features in the shapefiles that you want to import into Adobe Illustrator are visible. You may need to re-arrange the layers in the Layers panel on the left hand side if you can’t see something.

Finally, hide any features or sublayers in the shapefiles that you do not want to import into Adobe Illustrator. Simply uncheck the feature in the Layers panel to hide it. If you need finer control for removing an individual item, you can easily do that once we import it into Illustrator.

Don’t Worry About Appearance in QGIS

Don’t worry about what the map looks like in QGIS. There’s no need to adjust colors, line thicknesses, or anything else. We’ll do that in Illustrator. Adobe Illustrator gives you much better and finer control over the look of the map than QGIS does. The one exception would be if two features are blocking each other and you need to remove the fill of one so you can see the other.

Finally, if you’ve used a basemap, uncheck it from the layers panel on the left to hide it. The basemap will create all kinds of headaches if you import it into Illustrator. Alternatively, if you’re having issues with white features on a white background in QGIS, just change the background color. You can easily delete that solid background once you get it into Illustrator.

To change the background color, follow these steps.

  1. In the top menu, select Project > Properties. A window will open.
  2. Click on the “General” tab in the upper-left.
  3. In the fourth row down from the top, click on the white box to the right of “Background color” and select the background color you wish.

3. Create a Layout in QGIS to Easily Export Your Shapefiles into Adobe Illustrator

First, zoom and pan the map in your QGIS project to the exact level and position you want to display it in Illustrator. It doesn’t need to be exact, but you should include a little more than you intend to use. It’s easy to clip off the extra after importing the map into Illustrator.

Once your map is zoomed and positioned correctly, it’s time to create a layout so you can export it out of QGIS. In the top menu, select Project > New Print Layout. Follow the prompts to create your new layout. For best results, make sure the layout size is set to either US Letter or A4. Then click the “Add Map” button on the left-hand side.

Finally, click and drag your map so it fills the blank layout. You should see your map appear. If you didn’t get the entire page filled, simply click and drag each corner of the map out to the corners of the blank layout.

Congratulations, you’re ready to export your map out of QGIS. Don’t close the layout window just yet, because you’ll still need it in the next step.

4. Export Your QGIS Layout into SVG Format

Scalable Vector Graphics, or SVG, is an open-source XML-based framework for defining two-dimensional scalable vector images. It’s the most common type of vector image used in web-based applications today. The main advantage of vector images is that they can be scaled infinitely up or down without losing quality or becoming pixelated. As a result, you can cram a huge amount of data into a very small file. And best of all, Illustrator can automatically convert your .svg image into its default .ai format on import.

To export your shapefiles into .svg format, go back to your layout window. In the top window of the layout window (not the main QGIS dashboard), select File > Export Image as SVG. Follow the prompts to save the .svg file to your local hard drive.

SVG File Exported from QGIS Opened in a Web Browser

One thing to be aware of is that QGIS may give you a warning about some SVG’s not being exported correctly. I have not had any issues with SVG exports, but if your SVG’s do not export correctly, simply export your shapefiles as a .pdf file instead. In the layout window, select File > Export Image as PDF. PDF files are also a vector format, and you follow the exact same steps to import everything into Illustrator, regardless of whether your file is an SVG or PDF.

If you encounter this warning, continue exporting your SVG. It will more likely than not export just fine.

5. Place Your Exported SVG File into Illustrator

All right, we’re almost there. All that’s left to do is to import our shapefiles (in SVG/PDF format) into Adobe Illustrator. Once that’s done, let your creative side take over and have some fun.

First, open Adobe Illustrator and create a new file. You can use any size artboard you want. However, because I create these maps for use in my travel videos, I’ll use a 4K (3840×2160) artboard.

Second, create a new layer that will hold only your SVG file. Putting the SVG file into its own layer allows us to filter, parse, and extract specific elements of the SVG file into our Illustrator project. Then, once we’ve extracted everything, all we have to do is delete or hide the SVG layer to remove all of the extras.

Linking vs. Embedding Images in Adobe Illustrator

When you import any kind of image into Adobe Illustrator, you can choose whether to embed the file in Illustrator or just link to it. Linking the image file means that Illustrator will reference it from wherever it is on your computer. If you move or delete the image, it will disappear from your Illustrator project. Embedding, on the other hand, copies the image into Illustrator and saves it as part of the .ai file. That way, if you move or delete the original image file, it will still be in your Illustrator project.

Because your exported shapefile vectors are so small, I highly recommend you embed the SVG into Illustrator. Embedding the SVG into Illustrator is easy and straightforward.

  1. In the top menu, select File > Place.
  2. Navigate to the SVG File you exported from QGIS. Click “Add”.
  3. Click anywhere in your Illustrator window to place the SVG.
Your map will likely not look terribly glorious when you first import it into Adobe Illustrator

You should now see the SVG file that you exported from QGIS. However, it’s probably not in the right place in the Illustrator window, nor is it scaled correctly.

A Note on Moving and Scaling Your SVG File in Adobe Illustrator

Adobe Illustrator automatically separates the features in your SVG file to mirror the original shapefile. That’s a good thing, as it makes incredibly easy to separate out each element in Illustrator. However, if you’re not careful, you can easily move or scale features of your map out of place. Thankfully, it doesn’t take much to prevent things from moving out of place.

The easiest way to move or scale the SVG as a whole is to lock all of the other layers first. Because the SVG is in its own layer, then all we have to do is just hit Control + A on Windows or Command + A on a Mac to select all. With the other layers being locked, you’ve selected your entire SVG file without bothering anything else in the Illustrator file.

Second, make sure you hold down the Shift key when scaling the SVG. Doing so maintains the aspect ratio of the SVG. Without it, your map will become distorted and misshapen.

Positioning Your Map in Adobe Illustrator

it’s best to center your map in your Illustrator project, filling as much of the artboard as possible. However, make sure you leave room, particularly at the top, for any titles, headers, labels, and legends you would like to include.

At this point, it’s still perfectly fine if parts of the map extend beyond the boundaries of the artboard. We’ll delete those parts in the next section. And remember, you’re working with vectors, so you can infinitely scale them up or down without losing quality or pixelating.

6. Organize the components of the SVG into Layers in Adobe Illustrator

Depending on what you’re using the Illustrator map for, this can be one layer or many. It’s entirely up to you. However, do note that if you’re animating the map, every individual item or group of items that you’ll be animating as a single unit needs to be in their own layer. In other words, you can’t animate pieces of a layer. You can only animate the whole layer.

Additionally, if you have roads or routes on your map, make sure that you join the pieces of each route together so the route can be a single entity on the map. Having a route in several pieces can be an absolute nightmare if you’re trying to animate it. But even if it’s just going to be static, it’s still much easier to manage a single route than several pieces of it. To join paths in Illustrator, select each element of the paths you want to join and go to Object > Path > Join.

How to Extract SVG Components into Adobe Illustrator Layers

  1. Click the New Layer button on the bottom right of the Illustrator window to create a new layer.
  2. Go through the components of the SVG layer and find the ones you want to extract. This may take some trial and error by showing and hiding each piece.
  3. In the Layers panel in Illustrator, click and drag that component from the SVG layer to the new layer.
  4. Adjust the line width, colors, fills, strokes, opacities, etc. to set the final look or design of the feature you just moved.
  5. Add any features to the layer that were not in the SVG file. These are most often the feature labels you can add with Illustrator’s text tool.
  6. Repeat steps 1 through 5 for each feature layer you wish to create.
The Utah “Big 5” National Parks in Illustrator After Being Extracted From the SVG File

When you finish extracting the SVG components you’re using in your Illustrator map, there will likely still be features left over in the SVG layer that you’re not using. Putting the SVG file in its own layer makes it very easy to clean up the leftovers. If you know you’re not going to be using anything else in the SVG layer, you can go ahead and delete the layer. On the other hand, if you know you’re going to be using the leftovers or are not sure, simply hide the SVG layer so you can access it later.

Conclusion

Being able to export ESRI shapefiles into Adobe Illustrator opens up a whole new set of opportunities for content creators, artists, and other creatives to use maps. Creating professional branded, elegant, and easy-to-read maps in Adobe Illustrator will put you leaps and bounds ahead of the masses that are still using screenshots of Google Maps in their videos and presentations.

In the next tutorial, learn how to transform the extracted layers above into this.

In future tutorials, we’ll go over how to put the full Illustrator files together like you see in my travel videos. Then, learn how to animate your maps using both Adobe Illustrator and After Effects. In the meantime, we’d love to help you get started with your creative maps and animations. Please get in touch with us today to discuss your project and how we can bring your mapping visions to life.

Top Image: Warm Later Afternoon Light Provides a Dramatic Contrast Against Grey Winter Skies
Canyonlands National Park, Utah – December, 2021

The post How to Import Shapefiles into Adobe Illustrator appeared first on Matthew Gove Blog.

]]>
Does Your Website Make These 10 Mistakes with Hero Images? https://blog.matthewgove.com/2021/08/27/does-your-website-make-these-10-mistakes-with-hero-images/ Fri, 27 Aug 2021 16:00:00 +0000 https://blog.matthewgove.com/?p=3126 The hero image has been around for decades. However, it didn’t catch on in modern web design until only about 10 or so years ago. If you’re unfamiliar with the term, a hero image is the large banner image you see at the top of websites that takes up most, […]

The post Does Your Website Make These 10 Mistakes with Hero Images? appeared first on Matthew Gove Blog.

]]>
The hero image has been around for decades. However, it didn’t catch on in modern web design until only about 10 or so years ago. If you’re unfamiliar with the term, a hero image is the large banner image you see at the top of websites that takes up most, if not all, of the window when you first load the site. A heading, a very short description, and a call to action usually accompany them.

Hero image on the Apple home page
Apple is one of the best in the business when it comes to hero images.

When used correctly, a hero image is a great way to make positive first impressions that instantly builds credibility and trust for your brand. Given the popularity of hero images, it’s no surprise that many businesses and organizations that use them often feel like they could be getting more from them. Unfortunately, when you’re dealing with graphics and images, all it takes is one minuscule misstep to send your audience running for the exits.

1. Your Hero Image is not Telling Your Story

They say a picture tells a thousand words. That’s especially true with hero images. In fact, the less text that accompanies them, the better. However, keep in mind that reducing the amount of text shifts even more of the burden to your hero image. As a result, it puts even more pressure on you to ensure everything is perfect.

Your hero image should tell your story. Without even reading the text, your audience should have a pretty good idea of as many of the following as possible.

  • What you are selling or showcasing
  • Personality of your brand
  • Your brand’s mission and/or values

You can find some spectacularly terrible examples of web design from just a quick Google Image search. In this screenshot, can you figure out what this company does without reading any of the text?

Awful web design
A Terrific Example of a Terrible Hero Image

Put aside the font and color choices for a sec. A grainy image of a couple puffy clouds tells us nothing about the company! At first glance, you’d have no idea the website was about horses unless you read the text. What makes it even worse is that after reading the first two lines of text, you still have no idea what they do. It’s not until you get to the third line that they reveal that they sell horses.

So how do they make it better? First and foremost, the hero image should have an image of one of their horses. Then add a little personality. If they’re selling show horses, put a picture of one of their horses at a show. Selling to a summer camp? How about a picture of a kid on a horse actively engaging with an instructor? Anything is better than the clouds.

2. There’s No Clear Call to Action

I’ll be the first to admit, I have been guilty of this in the past. Without a call to action, your audience has reached the end of the road. And it’s often a dead end road. With no clear indication of where to go, a small fraction of your audience will poke around your navigation menu. A few more will turn around and back up. But the vast majority of visitors will simple hit the red “X” in the corner and leave. The lack of a clear call to action is the leading cause of prospects exiting your sales funnel.

A Minor Detail Makes a Huge Difference

We can actually use on of my own websites to demonstrate the effect of the lack of a call to action. The Matt Gove Photo site uses a large hero image on the home page with links to my most recent adventures. Because the site is focused on travel and outdoor adventure, the heading and subheading reference the specific adventure and the state or country in which it’s located. Underneath, you’ll find the call to action: links where you can view photos, blog posts, videos, and more. Now, how would you react if you landed on the site and those calls to action had suddenly disappeared?

Matt Gove Photo Home Page with Calls to Action Removed

When you look at that hero image, you really want to see the rest of the photos. But without a call to action, you have nowhere to begin. You’d have to go searching through the whole photo gallery to find them. I don’t know about you, but I’m far too lazy for that. I’d have a quick scroll through the home page and then probably leave.

Thankfully, that example is purely hypothetical. If you visit the site, rest assured that the calls to action are all still there.

Matt Gove Photo home page hero image
The Actual Matt Gove Photo Home Page Contains Links to My Most Recent Adventures

Amazing how such a small detail can make such a big difference, isn’t it?

Can’t Think of a Good Call to Action? Here’s What to Do.

So what should you do if you can’t think of a good call to action? Or maybe there actually is no logical path to your next step? When in doubt, give these a try. Your goal here is to keep your audience engaged, not make a sale.

  • Signup form for your email list, with a free giveaway to encourage people to sign up
  • An exclusive offer you won’t find anywhere else on the site
  • List of references where they can learn more about you or the website’s topic
  • A link to book an appointment, meeting, or phone call with you
  • Links to follow you on social media

3. There are Too Many Calls to Action

On the flip side, it’s easy to get caught up and include too many calls to action. In an ideal world, the clearest call to action you can make is to only have one. Having two is okay, especially if one is a “Learn More” link. However, three is pushing it in many circumstances, unless there is a clear and logical reason for it. On the Matt Gove Photo home page, that’s the case. The photos are clearly divided into three parts.

Under no circumstance should you have more than three calls to action associated with your hero image. Even with three, you risk overwhelming and confusing your audience with too many choices. Unfortunately, when you have too many choices, the one you make most often is simply to leave.

Let’s back up in time for a sec. We’ll go back to 2013. At the time, I had little experience when it came to web design and web development. Not surprisingly, I tried to cram way too much into the home page. To say it overwhelmed you with choices is an understatement. Not to mention I needed a few lessons in color theory.

Matt Gove Photo Home Page in 2013

Back in the present day, I cringe big time looking at that. You should too. But we must learn from our mistakes and experiences. My how things have changed since then.

4. Too Much Text or Copy Muffles the Effectiveness of Your Hero Image

As we discussed at the beginning, your hero image should do most of the heavy lifting for getting your message across. Keep your text to a bare minimum. It should consist of no more than:

  • Main Heading
  • Subheading
  • Short desciption – 1 or 2 sentences
  • Call(s) to Action

There is once exception to this rule when it’s okay to write more than a couple short sentences: coming soon ore pre-launch pages. The reason why? You need to be able to describe both what is coming soon as well as the benefits your audience will get once it launches. If you can do it only one sentence, more power to you. But for most of us, it takes a short paragraph.

Matt Gove Photo "Coming Soon" page hero image

5. The Contrast of Your Hero Image is High, so You Can’t Read the Overlaid Text

If you’ve ever tried to overlay text over any photo of the outdoors, you’ve likely run into this issue. No matter which color you choose for the text, there’s part of the image where you can’t read it. Your first thought may be to make the text multiple colors, but that never looks professional.

Let me let you in on an industry secret. Okay, it’s not really a secret, as just looking at the “Videos Coming Soon” page in the screenshot above gives it away. If you put a semi-transparent overlay on top of the image, the overlay mutes the effect of the high contrast and lets you easily read the text without having to change colors or squint at it from a weird angle. You want to find the perfect balance where the text is easy to read, but you can still clearly see what the image is behind the overlay.

For comparison, here’s the same “Videos Coming Soon” page with the semi-transparent overlay removed. Quite a difference, isn’t it?

6. Your Hero Image is too Small

There are two ways you can go with regards to size. First, the resolution of your photo may be smaller than the resolution of your screen. For making a professional, trustworthy first impression, it’s a complete disaster if that happens. Not only does such a mistake make you look like an amateur, it also looks like you just don’t care.

If Your Hero Image is too Small, You’ll Be First in Line at Amateur Hour

Now, I intentionally shrunk the image in a development environment to generate that screenshot. However, if you are dealing with very high-resolution screens (larger than 4K), you may run into an issue where your large hero image starts to adversely affect your page performance. There are a couple ways around it, both of which I employ on the Matt Gove Photo home page.

  1. Use JavaScript to asynchronously load the image at the same time the rest of the page loads. In other words, you load the page without the image and the image simultaneously.
  2. Use the background-size: cover CSS property to ensure that both dimensions of the hero image remain greater than or equal to the dimensions of the screen. Be aware that this can make your hero image grainy if its resolution is not optimized for larger screens.

Second, your hero image may not be taking up enough real estate on the page. In that case, you can easily argue that it’s no longer a hero image, but that’s a discussion for another day. Your hero image should take up the entire screen regardless of its size, orientation, and resolution. If your viewer’s eye is not immediately drawn to it, you’re doing it wrong.

You Can Shrink Your Hero Image to Tease What’s Below the Fold

There is one scenario where it’s perfectly okay to shrink your hero image: to tease what’s below the fold (the content you have to scroll down to see). If you have a look the next time you buy something online, you’ll find many businesses and e-commerce sites apply this strategy. I use it on my business’ website, too.

Matthew Gove Web Development hero image teases the content below the fold.
Don’t be Afraid to Tease Your Viewers with “Below the Fold” Content

7. Your Hero Image is a Low Quality, Under or Overexposed Photo

Your hero image should be one you would frame to hang up in your home or office. People should be oohing and aahing over it. Don’t use crappy images. Ever. If your photography skills aren’t up to snuff, you should either license a photo or hire a professional photographer to take and/or process your photos for you.

8. Your Unoptimized Hero Image is Suffocating Your Website’s Load Time

When your audience logs onto your website or application, they expect it to load. Fast. If your site takes more than a few seconds to load, you can kiss your audience goodbye. They won’t wait around for it to load. And losing your audience isn’t your only worry. Search engines will punish your website if they detect it’s unnecessarily slow.

Unfortunately, we’re barreling right towards a Catch 22. Large, and often bloated, images are the #1 cause of slow websites. So how do you maintain that lightning fast load time while at the same time being able to use beautiful, high-quality hero images?

  1. As we discussed a few sections ago, use JavaScript to asynchronously load the image. That way, the rest of the page loads without the extra weight of the image. At the same time, JavaScript loads the image and inserts it into the page at the same time the page is loading.
  2. Save your hero image in jpeg format. Other formats, such as png, are much larger and are not optimized to be used as hero images.
  3. Your hero image should not be larger than 4K resolution (3840 x 2160). This recommendation will likely change in the future, but screens larger than 4K are so rare these days, it’s not worth it yet. Consult your analytics to find out what screen sizes your audience uses. Then optimize your hero image for those screen sizes.
  4. Use a separate hero image that’s optimized for mobile devices to speed up mobile users’ performance significantly.

9. You’re Using Multiple Hero Images

Hero images were designed to be used one at a time, and one per page. If one hero image is bogging down your website, imagine what several will do. In addition to the performance issues, you risk overwhelming your audience with choices if you use multiple hero images on the same page. And we all know what happens when you do that.

In addition, sliders and carousels stopped being popular in 2010. Don’t use them. Search engines have a brutally difficult time crawling them, which can have a profoundly negative effect on your search engine optimization. Most SEO and conversion experts agree that they have little use 99% of the time. In addition to bogging down your site, the statistics just don’t justify their use anymore.

SlideAmount of Clicks
First Slide90%
Second Slide8.8%
Third Slide and Above1.7 to 2.3%
Source: Notre Dame University Web Development

10. A Hero Image May Not Be Right For You

If you feel you’ve done everything right with your hero image and still aren’t getting conversions, it may mean that hero images aren’t for you. There’s nothing wrong with that. Maybe you have home page content that is constantly being updated. Have a look at any news site out there. None of them use hero images. The same goes for certain e-commerce businesses. Amazon, Walmart, Home Depot, and Best Buy don’t use them, either.

If you don’t feel hero images right for you, don’t use them. Yes, they’re all the hype right now. And yes, they can be absolutely gorgeous. But they’re not for everyone. You’re the only one who can make the decision as to what’s best for you.

Conclusion

Well, that’s about enough butchering of my own websites as I can take. When used correctly, hero images can convert at an incredible rate and boost your credibility to levels you didn’t think possible. Unfortunately, that’s an incredibly difficult needle to thread. Hero images are astonishingly easy to screw up. I’ve been building websites since 2008 and I still find new ways to make mistakes.

However, we must continue to learn from our mistakes. Use analytics to your advantage. They’ll tell you why your hero image is not converting. Please reach out to us if you need any help. With our expertise in data science, web development, and graphic design, we’ll help you process your analytics and make sure that your hero image becomes a magnet for leads. The worst thing you can do is let it frustrate you.

Top Photo: A Desolate Road to Nowhere
Death Valley National Park, California – February, 2020

The post Does Your Website Make These 10 Mistakes with Hero Images? appeared first on Matthew Gove Blog.

]]>
Color Theory: A Simple Exercise in Mathematics and Graphic Design https://blog.matthewgove.com/2021/07/02/color-theory-a-simple-exercise-in-mathematics-and-graphic-design/ Fri, 02 Jul 2021 16:00:00 +0000 https://blog.matthewgove.com/?p=2476 We are exposed to color theory every single day of our lives. Most of the time, we don’t think twice about it. However, did you know that judgements of your credibility are 75% based on the design of your website? First impressions are 94% related to the look and design […]

The post Color Theory: A Simple Exercise in Mathematics and Graphic Design appeared first on Matthew Gove Blog.

]]>
We are exposed to color theory every single day of our lives. Most of the time, we don’t think twice about it. However, did you know that judgements of your credibility are 75% based on the design of your website? First impressions are 94% related to the look and design of your website. And 46% of customers base their purchasing decisions on the aesthetic appeal of your website. Indeed, color theory and graphic design is that important.

Unfortunately, the vast majority of people have a terrible eye when it comes to graphic design, and many organizations cut corners on their designs. While any of us can choose colors, professional graphic designers have a knack for choosing colors that are just stunning together. So how do they do it? They don’t just pull these colors out of thin air.

It turns out we can use mathematics to better understand color. The mathematical color theory we’re looking at today is aimed at web and application design, but you can certainly use it for painting your house, coordinating fashion outfits, or any other type of design.

The Color Wheel: The Foundation of Color Theory

Isaac Newton invented the color wheel in 1666. Mapping the color spectrum onto a circle easily allows us to identify relationships between colors. You probably saw a color wheel when you were in elementary school. However, you can easily find color wheels that professionals use through a quick Google Images search. Here’s an example of one.

The color wheel forms the basis for explaining color theory mathematically.

A New Take on Primary Colors

Time for another flashback to elementary school. Do you remember the primary colors? I know you do. If you’ve forgotten, they are are red, yellow, and blue, or RYB for short. You cannot make primary colors by combining mixtures of other colors.

Did you know that that’s not the only set of primary colors? Those primary colors you learned in elementary school are only telling part of the story. The other set of primary colors consists of red, green, and blue, or RGB. Wait, what? Nope, that’s not a type-o. You actually use the RGB primary color scheme in your day-to-day life than you do the RYB.

So how on earth can green possibly be a primary color? I thought yellow and blue made green. You’re right, but only partially right. Here’s the rest of the story. The RYB primary color scheme you were taught in elementary school applies to mixing colors of paint or ink. Whenever you mix colors of light, you use the RGB color scheme.

Where Do We Use the RGB Primary Color Scheme?

It’s everywhere. First and foremost, your eyes use the RGB primary color scheme to interpret color. Anything with a screen also uses it. Your phone does. So does your computer and your television. So do those electric signs you see on the freeway. The next time you’re in a studio or at the theatre, look up at the lights. You’ll see they are red, green, and blue.

Thankfully, mathematical color theory remains the same, regardless of which primary color scheme you’re using.

Denoting Color Mathematically

In order to apply mathematical theory to color, we’re going to have to put some numbers behind it. Isaac Newton, the man who invented the color wheel, was one of the greatest mathematicians of all time, so most of the heavy lifting is done for us. We simply use the RGB Model break the color down into its red, green, and blue components. You can think of it either as a three-dimensional vector or as a 1×3 matrix.

color = RGB(red, green, blue)

So what numbers do we put in each component? 0 to 100 would be a good guess. That’s actually an accepted way to do it, but when you’re working with computers, there’s a better way. Computers use the binary system, which uses powers of two. A single byte consists of 8 parts called bits. As a result, the maximum value a byte can hold is 28, or 256. We’ll set each component of our color to a number between 0 and 255.

black = RGB(0, 0, 0)
white = RGB(255, 255, 255)
red = RGB(255, 0, 0)
green = RGB(0, 255, 0)
blue = RGB(0, 0, 255)

Choosing a Coordinate System for Our Color Wheel

To fully understand color theory, we’ll need to plot the color wheel on a graph. By default, most people start with a cartesian (x, y) coordinate system. And cartesian coordinates work just fine for color theory. However, there’s one big catch. The color wheel is circular, which means we need to deal with angles. And in a cartesian grid, that means trigonometry, and lots of it.

I don’t know about you, but I’d rather not have to bring sines and cosines into this. Thankfully, there’s a much better coordinate system to use. And best of all, the only math you’ll need is addition and subtraction. There’s no trigonometry required.

Enter the Polar Coordinate System

Instead of a rectangular grid, the polar coordinate system is based on concentric circles around the (0, 0) coordinate. Instead of (x, y), polar coordinates are given as (r, θ). The r coordinate refers to the radius, or how far you are from the origin. Theta (θ) is the angle from a horizontal line that extends to the right from the origin. In degrees, theta is a number between 0 and 360.

Color theory can easily be explained mathematically using a polar coordinate system.

Convert RGB to Hue, Saturation, Lightness (HSL) to Make the Mathematics of Color Theory Even Easier

Here’s where the magic happens. The hue, Saturation, Lightness, or HSL model, is just another way to denote and analyze colors. Like RGB, it is comprised of three components. Can you tell which component will complement our polar coordinate system perfectly?

HueThe angle on the color wheel, from 0 to 360°. Red is 0°, green is 120°, and blue is 240°.
SaturationThe grey level, as a percentage. 0% is a shade of grey. 100% is full color.
LightnessHow light or dark the color is, as a percentage. 0% is black, while 100% is white.

The hue component overlays perfectly with our polar coordinate system. To perform color theory, all we need to do is add or subtract hue values to obtain complementary colors. No trigonometry required. You don’t even have to touch the saturation or lightness values. The process is breathtakingly simple.

  1. Convert your primary color to HSL notation. The nuts and bolts of that conversion is beyond the scope of this tutorial. However, I wrote a Python script that does the conversion so you can perform your own color analysis.
  2. Add and/or subtract the hue angles to determine your complementary colors. We’ll do some hands-on exercises with that below.
  3. Convert the colors in your color scheme back to RGB notation.

For the examples below, let’s use red as the primary color because θ = 0 for red. That way, the angles on the plots will make much more sense.

Complimentary Color Theory

The complimentary color is the color that is directly across the color wheel from your primary color. Mathematically, just add 180° to the hue of your primary color and plot it on your polar coordinate system.

hue_complimentary = hue_primary + 180
saturation_complimentary = saturation_primary
lightness_complimentary = lightness_primary

Real World Example of Complimentary Colors

Look no further than the world of North American sports to find logos that use complimentary colors.

Tricolor: Adjacent Color Theory

With adjacent colors, the goal is to have two additional colors that are compatible with your primary color. All three colors should be near each other on the color wheel. One of the adjacent colors should be slightly cooler than your primary color. The other should be slightly warmer than your primary color.

Adjacent colors work best with more subdued colors. When used with bright, vivid colors, they can really overwhelm your senses.

A Word About Angles in Color Theory

Using polar coordinates, your two adjacent colors are offset from your primary color by the same angle on the color wheel. Most designers find that 30° to 45° is the optimum range, but anywhere between 20° and 60° is acceptable. If you use an angle less than 20°, the colors will be so similar you’ll have a hard time telling them apart. Use an angle greater than 60°, and they’re really not adjacent colors any more.

In the equations below, the phi variable (φ) represents the angle your adjacent colors are offset from the primary. In the plot below, φ = 30°.

hue1 = hue_primary + phi
hue2 = hue_primary - phi

saturation1 = saturation2 = saturation_primary
lightness1 = lightness2 = lightness_primary
Using color theory to show adjacent colors on the color wheel
Adjacent Colors for Red, Offset by 30° on the Color Wheel

Real World Examples of Adjacent Colors

Many companies you interact with in day-to-day life use adjacent colors.

Tricolor: Triad Color Theory

The theory behind triad colors is identical to adjacent colors, with one distinct difference. Instead of being offset φ degrees from your primary color, triad colors are offset φ degrees from its complementary color. Instead of just a single complementary color, you’ll have two. If you’re looking for a tricolor scheme and have bright colors, triad colors work much better than adjacent colors.

Using a single triad color is also a great alternative to using a complementary color. Which one to use will largely depend on your project, but if you don’t like the look of your color scheme using a complementary color, try it with a single triad color. Out in the real world, there is no more textbook example of using a single triad color than the iconic bleu, blanc, et rouge of the Montréal Canadiens. Well, at least the bleu and rouge parts.

A Montreal Canadiens home jersey shows a textbook example of color theory
The Montréal Canadiens Iconic Red Home Sweaters, accented with a Blue Stripe. Image courtesy of NBC Sports.

Mathematically, triad colors are calculated the same way as the adjacent colors, except they’re offset from the complimentary color. The same rules for the angles apply here. In the plots below, let’s again use 30° as the offset angle.

hue_complimentary = hue_primary + 180
hue1 = hue_complimentary + phi
hue2 = hue_complimentary - phi

saturation1 = saturation2 = saturation_primary
lightness1 = lightness2 = lightness_primary
Showing triad color theory on a polar coordinate system.
Can you see where the Montréal Canadiens got their color scheme?

Real World Examples of Triad Colors

We’ll go back to sports team logos here. Can you spot the common thread in the color schemes? Do note that many of these teams use a single triad color like the Montréal Canadiens do.

So did you spot the common thread in the color schemes? Red, white, and blue are an incredibly popular triad color scheme in North American sports. It makes sense given the color scheme of the American flag. However, don’t forget that the Canadian flag had blue in it as recently as the 1960s.

Tetrad Color Theory: Make a Rectangle on the Color Wheel

Tetrad colors combine the best of complimentary, adjacent, and triad colors into a beautiful 4-color scheme. Using the naked eye, it’s incredibly difficult to pull off a good tetrad color scheme, but it becomes much simpler when you put the math behind it to work. When done correctly, if you plot the four points on the color wheel and then connect the dots, you’ll have a perfect rectangle.

Also called “Double Complimentary Colors”, it’s actually quite easy to come up with a tetrad color scheme mathematically.

  1. Start with your primary color.
  2. Select one of the adjacent colors to your primary color. It does not matter which one.
  3. Calculate the complimentary color from your primary color.
  4. The triad color is simply the complementary color of the adjacent color you chose in Step 2.
hue_complimentary = hue_primary + 180
hue_adjacent = hue_primary + phi
hue_triad = hue_adjacent + 180 = hue_complimentary + phi

saturation1 = saturation2 = saturation_primary
lightness1 = lightness2 = lightness_primary

While the plot below uses an offset angle of 30°, I find tetrad colors work much better with a larger angle. Many of our real-world examples use angles of at least 45 to 60°.

Color theory states that tetrad colors should make a rectangle on your color wheel using two sets of complimentary colors

Real World Examples of Tetrad Colors

You’ll need to look to the tech industry to find the best examples of tetrad colors in the real world.

Interestingly, there is one North American professional sports team that pulls off a tetrad color scheme incredibly well. Any guesses as to which team it is? I’ll give you a hint. It’s an NBA team.

The Oklahoma City Thunder logo uses tetrad colors extremely well.

Monochromatic Shading

Our final color theory is the simplest. You don’t have to worry about converting RGB to HSL notation. You’ll want to use RGB notation. Throw away your polar coordinates, too. They won’t be needed here.

Monochromatic shading is nothing more than making a lighter and darker version of your primary color. The secret to pulling it off is that both the lighter and darker versions must be scaled the same amount from your primary color.

The scaling factor should be a percent, in decimal form. In other words, use 0.25 to scale your colors by 25%. Like the tricolor schemes, scale in moderation. 25 to 60% is a pretty safe range.

red_light = red_primary * (1 + scaling_factor)
green_light = green_primary * (1 + scaling_factor)
blue_light = blue_primary * (1 + scaling_factor)

red_dark = red_primary * (1 - scaling_factor)
green_dark = green_primary * (1 - scaling_factor)
blue_dark = blue_primary * (1 - scaling_factor)
Monochromatic shading for a standard red color.

Our Strategy

On our websites, we employ a simple strategy. We start with a tetrad color scheme, choose primary and secondary colors from that, and compliment them with greys as necessary. However, we do actually use all 4 colors.

  1. Primary Color
  2. Secondary Color
  3. Accent Color that is used sparingly to complement the primary and secondary colors.
  4. Alert Color: A high-contrast color used to draw attention to certain items, such as error messages, warnings, sale announcements, etc.
  5. Greys accent headers, footers, and other parts of the website as needed

We also use monochromatic scaling to make buttons and links darker when you hover over them, and make them lighter when they’re disabled.

Conclusion

Choosing a color scheme can be incredibly difficult. While it’s no substitution for a professional designer, knowledge of basic color theory goes along way towards your success. Use color theory mathematics to know what you want prior to hiring a designer. They’ll be able to work much more efficiently, and you’ll save yourself some money as well.

If you want to explore color theory further and try out some of the color theory math for yourself, I’ve put Python scripts on the Bitbucket repository. And if you have any graphic design needs or just a general question, please don’t hesitate to get in touch today.

Top Photo: Brilliant Colors Light Up the Desert Sky During a Spectacular Winter Sunrise
Wittmann, Arizona – December, 2017

The post Color Theory: A Simple Exercise in Mathematics and Graphic Design appeared first on Matthew Gove Blog.

]]>
Python GeoPandas: Easily Create Stunning Maps without a GIS Application https://blog.matthewgove.com/2021/06/11/python-geopandas-easily-create-stunning-maps-without-a-gis-program/ https://blog.matthewgove.com/2021/06/11/python-geopandas-easily-create-stunning-maps-without-a-gis-program/#comments Fri, 11 Jun 2021 16:00:00 +0000 https://blog.matthewgove.com/?p=2415 Python is the world’s third most popular programming language. It’s also one of the most versatile languages available today. Not surprisingly, Python has incredible potential in the field of Geographic Information Systems (GIS). That potential has only barely begun to get tapped with libraries like GeoPandas. In the past, we’ve […]

The post Python GeoPandas: Easily Create Stunning Maps without a GIS Application appeared first on Matthew Gove Blog.

]]>
Python is the world’s third most popular programming language. It’s also one of the most versatile languages available today. Not surprisingly, Python has incredible potential in the field of Geographic Information Systems (GIS). That potential has only barely begun to get tapped with libraries like GeoPandas.

In the past, we’ve looked at many different uses for Python, including how to make basic GIS maps. Unfortunately, the Basemap module is quite limiting on its own. My biggest complaint about it is actually how the maps look. It’s far too easy to make low-quality maps that look like they’re stuck in the 1980’s.

Enter Python’s GeoPandas Project

The Python Pandas library is an incredibly powerful data processing tool. Built on the popular numpy and matplotlib libraries, it’s a sleek combination of power, speed, and efficiency. You can easily perform complex data analysis in just a fraction of the time you could with Microsoft Excel or even raw Python.

GeoPandas is an add-on for Pandas that lets you plot geospatial data on a map. In addition to all of the benefits of Pandas, you can create high-quality maps that look incredible in any publication and on any medium. It supports nearly all GIS file formats, including ESRI Shapefiles. And do you know what the best part is? You don’t even need a GIS program to do it.

Today, we’re going to learn how to use GeoPandas to easily make simple, but stunning GIS maps. We’ll generate each map with less than 40 lines of code. The Python code is easy to read and understand, even for a beginner.

Getting Started with GeoPandas

Before getting started, you’ll need to install GeoPandas using either pip or anaconda. You can find the installation instructions from their website below. Please note their warning that pip may not install all of the required dependencies. In that case, you’ll have to install them manually.

All right, let’s dive in to the fun stuff. As always, you can download the full scripts from the Bitbucket repository.

Exercise #1: Display an ESRI Shapefile on a Map

Before we do any kind of number crunching and data analysis, we need to make sure we can load, read, and plot a shapefile using GeoPandas. In this example, we’ll use a shapefile of Mexican State borders, but you can use any shapefile you desire.

First, let’s import the libraries and modules we’ll be using. In addition to GeoPandas, we’ll be using matplotlib, as well as contextily. The contextily library allows us to set a modern, detailed basemap.

import geopandas
import matplotlib.pyplot as plt
import contextily as ctx

Diving into the code, we’ll first read the shapefile into pandas.

shp_path = "mexico-states/mexstates.shp"
mexico = geopandas.read_file(shp_path)

A Word on Projections

If we were to plot the map right now, we’d run into a major issue. Do you have any guesses as to what that issue might be? The boundaries in the shapefile will not align with the boundaries on the basemap because they use different coordinate reference systems (CRS’s), or projections. In that event, you’ll wind up with a map like this.

The outline of US States lies projected over Canada when the basemap is in a different projection from the shapefile.
What happens when your shapefile is not in the same projection as your basemap.

While the basemap is in the Pseudo-Mercator Projection, the shapefile is in the North American Datum, or NAD-83, projection. The European Petroleum Survey Group (EPSG) maintains a standardized database of all coordinate reference systems. Thankfully, you only need one line of code to convert the shapefile to the Pseudo-Mercator Projection. The EPSG code for the Pseudo-Mercator Projection is 3857.

mexico = mexico.to_crs(epsg=3857)

Plot the State Borders and Basemap

With both the basemap and the shapefile in the same coordinate reference system, we can plot them on the map. First, we’ll do the shapefile. We’ll pass the plot() method three parameters.

ax = mexico.plot(figsize=(12,8), alpha=0.5, edgecolor="k")

Now, let’s use the contextily library to add the basemap. You can set the zoom level of the basemap, but I prefer to let Geopandas figure it out automatically. If you zoom in too much, you can easily crash your Python script.

ctx.add_basemap(ax)

Finally, save the figure to your hard drive.

plt.savefig("mexico-state-borders.png")
Map of Mexican State borders, created with GeoPandas.

There’s still plenty of room for improvement, but our map is off to a great start!

Exercise #2: Use Layers to Map a Hurricane’s Cone of Uncertainty

Layers make GIS, graphic design, and much more incredibly powerful. In this example, let’s stack three layers. We’ll generate a map of the cone of uncertainty of a hurricane. If we can generate the plot quickly, warnings and evacuation orders can be issued, and we can save lives. We’ll look at Hurricane Dorian as it bears down on Florida and the Bahamas in 2019.

The National Hurricane Center GIS Portal

The National Hurricane Center maintains a portal of both live GIS data as well as archives dating back to 2008. While I included the Hurricane Dorian shapefiles in the Bitbucket repository, I encourage you to browse the NHC archives and run our script for other hurricanes. Their file naming system can be a bit cryptic, so you can look up advisory numbers in their graphics archive.

Using the Hurricane Dorian shapefile as an example, here’s how the filename breaks down. The filename is al052019-033_5day_pgn.shp

  • al: Atlantic Hurricane
  • 05: The fifth storm of the season
  • 2019: The 2019 calendar year
  • 033: NHC Advisory #33
  • 5day: 5-Day Forecast
  • pgn: The polygon of the cone of uncertainty.

The NHC also provides shapefiles for the center line and points of where the center of the hurricane is forecast to be at each subsequent advisory. We’ll use all three in this example.

Python Code

Like the Mexico map, let’s start by importing the modules and libraries we’ll be using.

import geopandas
import matplotlib.pyplot as plt
import contextily as ctx

There are three components of the cone of uncertainty: the polygon, the center line, and the points where the center of the storm is forecast at each subsequent advisory. Each has its own shapefile. We’ll use a string substitution shortcut here so we don’t have to retype the filename three times. The .format() method substitutes the parameter passed to it into the curly brackets in the filepath.

SHP_PATH = "shp/hurricane-dorian/al052019-033_5day_{}.shp"
polygon_path = SHP_PATH.format("pgn")
line_path = SHP_PATH.format("lin")
point_path = SHP_PATH.format("pts")

Now, read the three shapefiles into GeoPandas.

polygons = geopandas.read_file(polygon_path)
lines = geopandas.read_file(line_path)
points = geopandas.read_file(point_path)

For the projections, we’re going change things up slightly from the Mexico map. Look at the x and y-axis labels of the Mexico map. They’re in the units of the projection instead of latitude and longitude. Instead of using the pseudo-mercator projection let’s use the WGS-84 projection, which uses EPSG code 4326. WGS-84 uses latitude and longitude as its coordinate system, so the axis labels will be latitude and longitude.

polygons = polygons.to_crs(epsg=4326)
lines = lines.to_crs(epsg=4326)
points = points.to_crs(epsg=4326)

Layering the Shapefiles on a Single Map

Before plotting the shapefiles, think about how you may want to color them. Because we’re dealing with a Category 5 hurricane that’s an imminent threat to population centers, let’s shade the cone red. While we’re at it, let’s make the center line and points black so they stand out.

The facecolor parameter defines the color a polygon is shaded. We’ll also make the cone more transparent so you can see the basemap underneath it better. That way, there’s no doubt as to where the storm is heading.

To stack the layers on a single map, define a figure (fig) variable with the initial layer. Then reference that variable to tell GeoPandas to plot each subsequent layer on the same map (ax=fig).

fig = polygons.plot(figsize=(10,12), alpha=0.3, facecolor="r", edgecolor="k")
lines.plot(ax=fig, edgecolor="k")
points.plot(ax=fig, facecolor="k")

Since this map would be published to the public in the real world, let’s spruce it up with a title and axis labels so there are no doubts about our warnings and messaging.

plot_title = "Hurricane Dorian Advisory #33\n11 AM EDT      1 September, 2019"
fig.set_title(plot_title)
fig.set_xlabel("Longitude")
fig.set_ylabel("Latitude")

Correctly Project the Basemap into WGS-84

The last map layer is the basemap. Because the basemap is not in the WGS-84 projection by default, we’ll need to pass that as well. To avoid type-o’s, we’ll reference it from one of the shapefiles that’s already in the WGS-84 projection. We’ll also manually set the zoom level to optimize the size and placement of state and city names on the basemap.

ctx.add_basemap(fig, crs=polygons.crs.to_string(), zoom=7)

Finally, save the figure to your hard drive.

plt.savefig("hurricane-dorian-cone-33.png")
GeoPandas map of Hurricane Dorian's cone of uncertainty, with colored basemap.

Plenty of Room for Improvement

That’s a perfectly fine map, but I believe we can do better. While the cone itself looks great, the basemap leaves a bit to be desired. City and state labels are hard to read, especially when they’re inside the cone. The basemap looks blurry, no matter the zoom level you set it too.

Additionally, the green terrain draws the eye away from the cone. In emergency situations like a major hurricane making landfall, you want to convey a bit of urgency. The red just doesn’t “pop” off the page.

So how do you fix the map to convey more urgency? Change the basemap. The terrain is too distracting. Ideally, when you look at the map, you should instantly be able to identify the map’s location using the basemap. After that, though, the basemap should “fade” into the background, allowing your reader to focus on the data. Using muted or greyscale colors on the basemap is the best way to accomplish that.

Thankfully, GeoPandas provides a good selection of basemaps. Have a look at the basemaps in that link (at the bottom of the page). Can you identify any basemaps that use muted or greyscale colors? The one that catches my eye is called “Stamen Toner Lite”.

Updating Our Python Code

Updating our script is easy. When you call the add_basemap() method, you can specify which basemap you use by passing it the source parameter.

ctx.add_basemap(fig, crs=polygons.crs.to_string(), source=ctx.providers.Stamen.TonerLite)

After running the script, the difference is striking. It’s amazing the difference just changing a few colors makes.

GeoPandas map of Hurricane Dorian's cone of uncertainty, with greyscale basemap.

So how did we do? Instantly identify the location on the map? Check. Eye instantly drawn to the red? Check. The red pops off the page? You bet. For a final comparison, here’s the actual graphic from the National Hurricane Center. I’ll let you decide which map you like best.

Official NHC Advisory for Hurricane Dorian – 11 AM EDT on 1 September, 2019

The Hurricane Center actually provides all of the GIS data and layers to recreate their official advisory graphics. Unfortunately, that’s outside the scope of this tutorial, but we’ll create those maps in a future lesson.

Pro Tip: Use this Python script in real time this hurricane season. You just need to change the shapefile path to the live URL on the National Hurricane Center Website.

Conclusion

It wasn’t too long ago that you needed expensive GIS software to make high-quality, publication-ready figures. Thankfully, those days are forever behind us. With web-based and open-source GIS platforms coming online, geospatial data processing is not only becoming much more affordable. It’s also gotten exponentially more powerful.

This tutorial doesn’t even begin to scratch the surface of what you can do with Python GeoPandas. As a result, we’ll be exploring the GeoPandas tool much more as we go though this summer and into the fall.

In our next tutorial, we’ll be analyzing data from one of the busiest and deadly tornado season in US history. Make sure you come back later this month when that drops. In the meantime, please sign up for our email newsletter to stay on top of industry news. And if you have any questions, please get in touch or leave a comment below. See you next time.

Top Photo: A Secluded Stretch of Beach on the Intracoastal Waterway
St. Petersburg, Florida – March, 2011

The post Python GeoPandas: Easily Create Stunning Maps without a GIS Application appeared first on Matthew Gove Blog.

]]>
https://blog.matthewgove.com/2021/06/11/python-geopandas-easily-create-stunning-maps-without-a-gis-program/feed/ 1