fx - SIMPLE MAP SETTINGS

Home navigation:   NPGeoMap Properties Dialog > Dynamic Map > Simple Map Presentation >

fx - SIMPLE MAP SETTINGS

Zum deutschen Handbuch wechseln NPGeoMap

Version 2.50.84, 07.12.2017

SimpleMaps
Create several Simple Map Blocks for individual usage and presentation.

maps
Set coordinates for each Simple Map Block and enable each block individually.

Darstellung
Set presentation, MouseOvers (Tooltips), PopUps and Sense visualizations in PopUps for each Simple Map Block.

click to expand

click to expand

 

The values for nearly all features may be entered as calculated formulas or variables.

For detailed information about notation in this dialogs go to chapter The fx‑editor.

SIMPLE MAP SETTINGS

SETTING / VALUES

EXPLANATION

 

 

SimpleMaps 

 

caption

text

custom name for the whole Simple Map Layer (default is "Simple Maps")

Custom name for the Simple Map layer.
This name appears in the Layerswitcher, the Legend and the Selection Menu. There's another feature "caption" in every Simple Map Block below to rename each of them.
(All layers in the object can be renamed - read more about in the Expert Settings.)

active

true

all Simple Maps enabled (Standard)

false

all Simple Maps disabled

Feature to basically enable or disable all Simple Map blocks.

maps

[

{SimpleMaps Block},

{SimpleMaps Block}

]

After "maps": one of the two default Simple Map blocks begin.
The individual blocks are enclosed by curly brackets {} and separated by comma - see screenshot on the right. All blocks together are enclosed by square brackets [] .
You can add several Simple Marker blocks by copy-paste and remove them again. Therefore several groups of points/Markers can be created. The individual blocks can be edited completely independently.

click to expand

click to expand

 

 

 Simple Map Block

active

true

this Simple Map is enabled (default)

false

this Simple Map is disabled

Enables or disables this Simple Map block.
This feature may be useful to define a Sense variable and set a button in the application, so the user can switch on and off this Simple Map block. With the Layerswitcher it can be hidden/unhidden as well - but in that way the data will be loaded anyway, therefore this is more a quick tool when working on the map. To increase performance in the app better actually disable the Maps with this feature, if you don't need them.

coordinates

coordinates

Simple Marker coordinates, as well as an ID, a Name and numeric values for "KPI", "Color%" and "Size%"

This feature is not only for setting the coordinates, but also for setting an ID, Name, KPI, Color% and Size% for a Simple Map block.
These at least three (ID, Name and Coordinates) up to five (ID/Name/Coordinates/KPI/Color%) settings create a table in the background, just like the Dimensions of Dynamic Markers and Dynamic Maps. Therefore each row assigns individual values to each Simple Map Polygon, which then may be applied dynamically - just like Dynamic Maps do. In contrast to them, the range of dynamic input of Simple Maps is reduced to these five specific fields.

000_warning The Sense formula Concat() with the qualifier DISTINCT always has to be used for dynamic entries. Aggregation functions like Sum() or Max() always have to be enclosed additionally by aggr().
Read more further below.
 

Classes:
"KPI" and "Color%" and expect numeric values.
The KPI setting provides a variable used in Labels, MouseOvers or PopUps.
"Color%" is the source for the Class, which automatically generates dynamic colors for the Simple Map Polygons. In this way sales, volumes, weighting and other KPIs may be displayed dynamically. Even synthetic Legends can be configured, by assigning "types".
For example all Simple Map Polygons with the type-value "1" could be yellow and "2" blue - the former are "sales area 1" and the others "sales area 2" - both in the same Simple Map block.
To do so enter the Class ID in the feature colorclass at the end of this dialog - the Classes themselves can be configured in the fx‑editor COLOR & SIZE CLASSES.

Performance:
Attention - more fields/columns mean longer loading times. Therefore you should only use and enter the fields you really need.
Further the order of the settings must be maintained - so the fields can only be skipped from right to left (first "Color%", then "KPI"). For example if "Color%" is needed, "KPI" has to be entered as well. The fields you don't need but can't skip may be just entered like ' ' (empty).

Coordinates Format and Notation:
Simple Maps can only be created with coordinates in WGS 84 projection as Encoded Polylines or with NPGeoMap map files - for details go to developers.google.com.
There are two options for the coordinates source:

via QlikView Script
The coordinates are loaded inside the Sense Script. Just set the respective Sense Field containing them.
Advantage: If you pass on your Sense app, you don't have to add an extra file with the map coordinates, because they are already inside the app.

 via Map File
Let NPGeoMap load the coordinates out of a map file. Therefore just set the map file name.
The most important maps are already included in your NPGeoMap Extension and about 400 further maps may be downloaded from the NPGeoMap website. They all have to be saved within the NPGeoMap Extension path (sub folder "maps") - like for example "US_1.geo".
Advantage: As Sense doesn't have to load the coordinate data as well, the performance of your app increases a lot.

Notation of the whole feature:
All fields together have to be entered as follows:

ID%NAME%ENCODEDPOLYLINE%KPI%COLOR;

1.A unique ID for each record/Polygon
(accessible via variable [#ID] in label, mouseover and popup)
 percentage sign 

2.Name - this field may contain any kind of information
(accessible via variable [#Name] in label, mouseover and popup)
 percentage sign 

3.Coordinates in Encoded Polyline format
 percentage sign 

4.KPI - Key Performance Indicator, for example "Sales"
(accessible via variable [#KPI] in label, mouseover and popup)
 percentage sign 

5.Numeric values for automatically generated colors for Simple Map Polygones via Classes
 percentage sign 

There must be no spaces between the entries and the decimal separator has to be a dot.

Several Polygons (coordinates) have to be separated by semicolon (beware when loading the script):

ID%NAME%ENCODEDPOLYLINE;ID%NAME%ENCODEDPOLYLINE;ID%NAME%ENCODEDPOLYLINE;

Example:
1%Texas%spd|D`xgnObFa...;1%California%yoa|FnlttVusIr...;

The whole feature in the fx-Editor looks like that:

"coordinates": "1%Austria%kwn{GieyyAdHoBhHbISh[nDfFr@vN|NrRpNnD~TeEt`@nOuBrSzIz]z`@hAfY[...]",

Since the code volume when entering Map coordinates directly would be much to big (in contrast to Simple Markers), this is only a theoretical example for better understanding.

Instead of entering the Encoded Polylines directly, regular practice is to use Sense variables, formulas or especially fields.
000_warning The Sense formula Concat() with the qualifier DISTINCT always has to be used for dynamic entries. Aggregation functions like Sum() or Max() always have to be enclosed additionally by aggr().

Example: Concat(aggr(Sum(Sales),ID))

Separator has to be a semicolon.
Please note that Sense elements are handled as text in JSON, therefore the JSON string must be "interrupted" with single quotes ' ' and the "parts" connected with ampersand & (see details in chapter The fx‑editor) - except when setting a map file name, as it's not a Sense field, but handled like "text":

Coordinates are inside a QlikView Field:

Concat(DISTINCT ID&'%'&NAME&'%'&COORDINATES&'%'&KPI&'%'&COLOR%,';')

Coordinates are loaded from a map file:

Concat(DISTINCT ID&'%'&NAME&'%US_1.GEO%'&KPI&'%'&COLOR%,';')

Example (only required entries):

Concat( {1} DISTINCT State&'%'&''&'%'&EncodedPolylines,';')

Example (with entries KPI and Color%):

Concat(DISTINCT ID&'%'&State&'%'&EncodedPolylines&'%'&aggr(Sum(Sales),ID)&'%'&aggr(Sum(Sales),ID),';')

The whole feature in the fx-Editor looks like that:

"coordinates": "' & Concat(DISTINCT ID&'%'&State&'%'&Coordinates&'%'&aggr(Sum(Sales),ID)&'%'&aggr(Sum(Sales),ID)),';')&'",

Or with a map file:

"coordinates": "' & Concat(DISTINCT ID&'%'&State&'%US_1.geo%'&aggr(Sum(Sales),ID)&'%'&aggr(Sum(Sales),ID)),';')&'",

You can also just copy one of the two template lines above in the expression dialog.

To always display the whole Simple Map in this block, regardless of taken selections, use the Sense identifier {1} :

Concat( {1} DISTINCT ID&'%'&''&'%'&COORDINATES,';')

Example (only required entries):

Concat( {1} DISTINCT State&'%'&''&'%'&EncodedPolylines,';')

The whole feature in the fx-Editor looks like that:

"coordinates": "' & Concat({1}DISTINCT ID&'%'&Name&'%'&Coordinates,';')&'",

If additionally to using the identifier {1} the feature layer further below is set to "1", a Static Simple Map can be created.

 
For detailed information about notation in this dialogs go to chapter The fx‑editor.

order

number

order of displayed Simple Map Blocks - number beginning at 1 for top layer

The numbers in this feature inside each Simple Map Block define their rendering order - the order in which the layers are displayed.
For example in the screenshot on the right the layer order is configured as follows:

Simple Map 1 has got order 1 and displays the US Counties (map file: "US_2.npgp" - selected is Palm Beach)
Simple Map 2 has got order 2 and displays the US States (map file: "US_1.npgp" - selected is Florida)
Simple Map 3 has got order 3 and displays the US Country Border (map file: "US_0.npgp")

click to expand

click to expand

caption

text

custom name for this  Simple Map block (default is "Simple Maps 1")

Custom name for this Simple Map block.
This name appears in the Layerswitcher, the Legend and the Selection Menu. There's another feature "caption" further above to rename the Simple Maps in general.
(All layers in the object can be renamed - read more about in the Expert Settings.)

 

 

Set presentation, MouseOvers (Tooltips), PopUps and Sense visualizations in PopUps for each Simple Map block.

bordersize

number

Simple Map border size (default is 0.5)

Polygon border size for this Simple Map in pixel.

color

color

Simple Map fill color (default is white)

Polygon fill color for this Simple Map.
Use Classes for automatic generated colors.

When setting colors you can use Hex-Codes, HTML color names or RGB
Example: color red = #FF0000 or red or RGB(255, 0, 0)
(Detailed information in chapter The fx‑editor)

bordercolor

color

Simple Map border color (default is grey)

Polygon border color for this Simple Map.

When setting colors you can use Hex-Codes, HTML color names or RGB
Example: color red = #FF0000 or red or RGB(255, 0, 0)
(Detailed information in chapter The fx‑editor)

opacity

number

Simple Map transparency in percent (default is 50)

Transparency of the fill color of Markers in percent:

0% - colors are covering
100% - completely transparent

label

content

Simple Map label

Simple Marker labels are displayed below the Simple Markers, however you can additionally configure the offset and further settings for labels in the menu area Polygon Label Settings outside this expression dialog. Basically labels contain only text, but you can also use Sense variables and formulas or these NPGeoMap #Hashtag Variables, provided in the feature coordinates above:

[#Name]

[#ID]

[#KPI]

Example:
"label": "[#Name]"

Labels can be edited with line breaks (using Chr(13)), but it is not possible to use HTML here.
See details about these variables in chapter The fx‑editor.

labelsize

number

Label size in pixels (default is 12)
 

Label size in pixels

labelcolor

color

Label font color (default is black)
 

Label font color
 
When setting colors you can use Hex-Codes, HTML color names or RGB
Example: color red = #FF0000 or red or RGB(255, 0, 0)
(Detailed information in chapter The fx‑editor)

mouseover

content

Simple Map MouseOver content

MouseOver (Tooltip) for Simple Map Polygons.
It appears next to the cursor, if it hovers on a Polygon.
This text may contain HTML, like for example a <br> tag to set a line break. Furthermore a delay and the duration time of MouseOvers can be configured in the Expert Settings.
Use Sense variables, fields and formulas for dynamic content
or these NPGeoMap #Hashtag Variables provided in the feature coordinates above:

[#Name]

[#ID]

[#KPI]
 

Example:

"mouseover": "Hello World",

"mouseover": "[#Name]",

Example with dynamic content:
"mouseover": "[#Name]<br>from [#ID]",

(See details about notation in chapter The fx‑editor).

 

000_warning Important: If you want to use local image files in HTML, you have to indicate the Sense image path - read details here.

000_pinTip: There's a CSS file "info.css" located in the NPGeoMap Extension directory (subfolder "css"), which can be customized to define the default presentation of PopUps, MouseOvers and SketchBoxes.
(If you configure this file make sure to save a backup, when installing an NPGeoMap update - the actual file will probably be replaced.)

More information about integrating Sense fields or formulas and further details on notation see chapterThe fx‑editor.

click to expand

click to expand

popup

content

Simple Map PopUp content

A PopUp is a kind of dialog or a small window, that opens or "pops up" if you click on an item (Marker, Polygons,...), for which a PopUp is defined. NPGeoMap can display text and dynamic content in a PopUp.
The whole PopUp content can be edited with HTML.
Use Sense variables, fields and formulas for dynamic content
or these NPGeoMap #Hashtag Variables provided in the feature coordinates above:

[#Name]

[#ID]

[#KPI]

Example:

"popup": "Hello World",

"popup": "[#Name]",

(See details about notation in chapter The fx‑editor).
 

In the following feature qvchart you can also add any Sense object or chart in this PopUp. The content you add at this point will appear just above the Sense visualization.

000_warning Important: If you want to use local image files in HTML, you have to indicate the Sense image path - read details here.

000_pinTip: There's a CSS file "info.css" located in the NPGeoMap Extension directory (subfolder "css"), which can be customized to define the default presentation of PopUps, MouseOvers and SketchBoxes.
(If you configure this file make sure to save a backup, when installing an NPGeoMap update - the actual file will probably be replaced.)

If the feature "popupautoclose" is disabled in the Expert Settings, you may keep several PopUps open at the same time.

More information about integrating Sense fields or formulas and further details on notation see chapter The fx‑editor.

click to expand

click to expand

qvchart

QV object ID

Sense object ID

Feature for displaying any Sense visualizations in the PopUp. Just fill in the Sense object ID (see screenshot on the right) of the visualization you want to use.
Basically all kinds of Sense objects can be used, however this feature is optimized for displaying Sense Charts. The only requirement is to keep the Sense object on the same sheet. It further will be displayed in the size it is on the sheet, so don't minimize it. The best option to hide it is to drag it behind another object, for instance to layer it under the NPGeoMap object.
By using the PopUp Variables in the Expert Settings the Sense visualization can be restricted to the values of the variables, like for example the current selections.

click to expand

click to expand

layer

1

static layer

2

dynamic layer (default)

Type of layer for this Simple Map Block:

1 = static layer
Simple Map stays in the background - no selections, PopUps or MouseOvers.

2 = dynamic layer
Simple Map is in the foreground - selections are possible by the use of the dynamic dimension of the ID in the coordinates above, as well as PopUps and MouseOvers.

selection

number

type of selection (default is 2)

Type of selection for this Simple Map Block:

 -1 = OFF, no selection possible
  1 = ON, selection by the use of values in a Sense Listbox
  2 = ON, selection by the use of the Polygon dimension set in Polygon Dimension

listbox

sense fieldname

Sense fieldname used with selection type 1

If the feature selection above is set to 1, fill in here the fieldname of the concerning Sense field containing the selection values.

colorclass

class name/ID

Class for automatically generated colors for Simple Map Polygons of this block (default is "EVEN_GRADIENT_COLOR")

Name (ID) of the Class for automatically generated colors for the Simple Map Polygons of this block, configured in the expression fx - COLOR & SIZE CLASSES.
Default options:

EVEN_GRADIENT_COLOR

EVEN_RANGE_COLOR

FIXED_RANGE_COLOR

QUANTILE_RANGE_COLOR

Source for calculating the Classes is the field/entry "Color%" in the feature coordinates at the beginning of each Simple Map block.
Read more about Classes here.