Customizing and converting maps to .shp files
WebSphere Dashboard Framework leverages ESRI Shapefile (.shp) files to render maps. Such map files are available from a variety of sources, including those on the Internet, but be sure to adhere to copyright and download requirements if you use them. To avoid any legal questions concerning the use of third-party maps, you can create your own maps from the world map and United States map provided with WebSphere Dashboard Framework instead. The ILOG JViews Maps builder tool also gives you the ability to convert other maps to the .shp format from other well known formats, such as TIGER/Line, MapInfo Interchange Format, GTOP30-DEM, GeoTIFF, DTED, and so on.
If your project requires a map that is not included with the default WebSphere Dashboard Framework maps, you can use
IBM ILOG JViews Maps to modify a default style. This article describes two methods for customizing maps.
- Using ILOG JViews Maps to work with layers to create custom maps.
- Using ILOG JViews Maps to create a map file and edit it in a text editor.
The article also explains how to add a custom map to a dashboard application.
Customizing a map using ILOG JViews Maps
This example shows you how to create a new map of South America from the world map that ships with WebSphere Dashboard Framework to use in a dashboard application.
- Open ILOG JViews Maps - Map Builder.
- Click File -> New Map.
- Click File -> Add Map Data to add the world map.
- Navigate to the WebContent\solutions\dashboard\chartstyles folder in your WebSphere Dashboard Framework workspace project folder. Select the world map and click Open.

- In the Map Layers tab, double-click the layer ESRI/Shape to see the layers in this map.
The default world map has one layer called "ESRI/Shape."
- Right-click ESRI/Shape and click Create Filtered Layer.
This option allows you to create children layers (for example, layers by continent or country). Using the ILOG JViews Maps builder tool, you can create a map with units as small as a single country from the world map and a state from the United States map. The option Create Simplified Layers creates layers that produce a smaller file size.

- Select the criteria for the filtered layer. For this example, select "CONTINENT," Equals," "South America."

For more information about layers, see "Working with layers in the default Dashboard Framework world and United States maps" later in this article.
- Click File -> Export.
- In the Export Map dialog box, select the layer you want to export and click select Vector Exporter: Export to Shape.

- Click Settings and select the folder you want this filtered map to be saved to.
- Click Export to save the .shp file with the name and location you chose.
- Close ILOG JViews Map Builder. You do not need to save the map unless you expect to work with the map again.
You can now use the resulting .shp file in a Dashboard Framework application.
Working with layers in the default Dashboard Framework world and United States maps
To help you see the sections of maps that you can create from the default maps provided with WebSphere Dashboard Framework, create a filtered layer as described in Steps 6 and 7 above, but use the "are grouped together" selection instead. You can also use this method to create multiple layers and then delete the ones you do not need.
- Create a filtered layer that highlights the map in different colored sections.
- For the world world map
To see all the continent values in the default world map, select CONTINENT, are grouped together.
To see all the country values, select WORCNTRY_1, are grouped together.
- For the United States Map
To see regions in the United States map, select To see states, select NAME, are grouped together.
- Right-click a region in the map and click Select to see its value.
Using ILOG JViews Maps and a text editor to customize maps
If you are unable to do the customizing you want to do with layers in the Map Builder tool, follow these steps to create a map file in ILOG JViews Maps and then use a text editor to change specific values in the map.
- Open ILOG JViews Maps - Map Builder.
- Click File -> New Map.
- Click File -> Add Map Data to add the map you want to customize.
- Save the file in .ivl format, which saves the map as plain text.
- Open the .ivl file in a text editor.
- Make the changes you want to make and save the file.
- Open the JVIews Maps Map builder and click File -> Open Prepared Map to open the .ivl file you edited.
- Click File -> Export.
- Select Vector Exporter: Export to Shape.
- Click Settings and select the folder you want this result map to be saved to.
- Click Export to save the .shp file with the name and location you chose.
- Save the map and close ILOG JViews Map Builder.
You can now use the resulting .shp file in a Dashboard Framework application.
Adding a customized map to a project
- Open the project that will include the new map in WebSphere Dashboard Framework.
- Open the Map builder.
- Click the ellipses (...) next to the Map File field.
- In the Choose File tab, click Add file to project.

- Specify the custom .shp file and click Open.

- Specify where you want to add the file in the project and click OK.

- Click the ellipses (...) next to the Map File field again.
- Select the file you just added to the project and click OK.
When you return to the builder window, you see the new file in the field.

- Make any other changes you need to make in the builder, then close and save the builder.