MAPresso: Parameters



Basics, Layout
Geometry
Data
Symbolizaton
Feature
Other

Parameters in red are required.

Parameters with *: can be set as default for all themes and datasets (e.g. mtyp=1) or for each dataset of a theme (e.g. mtyp_3=1) of by substituting * by the dataset number (mtyp_3_2=1; mtyp3 is equivalent to mtyp_1_3).

Parameters in italics indicate deprecated parameters.
Colors have to be defined in a RGB color system (hexadecimal as #6730c7 or decimal with dots: 103.48.199).

To start it is enough to define the number of areal units and an appropriate geometry. There are default values for all other parameters.

Texts: For special characters there are special escape sequences (starting with $)

Basics, Layout

nobs
Number of areal units.
language
Language (of dialogs, menus) (en: english / de: deutsch / fr: français / it: italiano); If the language parameter is a list (e.g. "en,de,fr") you can choose the language under the help menu.
country
Country code.
xmap / ymap
Position of the top left corner of the map (0 / 0).
 
xleg / yleg
Position of the top left corner of the legend (2 / 7).
fleg
Size factor of the legend (1.0).
boxw / boxh / dybox
Height and width of a nominal legend box. dybox: vertical space between two boxes (29 / 18 / 5).
box
Maximal rectangle (xmin, ymin, xmax, ymax). No further zoom out than to this box is possible. Default: no zoom out limits.
loglevel
Level of logging messages: trace, debug, info, warning, error (t, d, i, w, e).
splash
Name of the splash image appearing at program start (images/about.gif).
about
Name of the about image appearing at the about menu item (images/about.gif).

Geometry

geo*
URL or relative path of the polygons in "psc" format (with extension ".psc"). This kind of outline data set may be compressed and end in "psc.gz".
or
URL or relative path of the circles in "cir" format (with extension ".cir"). The circle format is usually the result of a Dorling cartogram.
or
URL or relative path of the circles in "cxy" format (with extension ".cxy"). The circle format is usually the result of a Dorling cartogram.

ARC/INFO shapefile format: use shp2psc to convert such a file to the psc format.

Normally there is just one geometry, you use "geo", otherwise you would need "geo1", "geo2", etc.
geoname*
Name of the geometry which apears in the pop-up-menu (only when there is more than one geometry).
nam / una / nau
URL or relative path of the areal unit names (with extension ".nam")
una, nau: File of the same structure but saved as Unicode text.
lab / ula / lau
URL or relative path of the areal unit labels (only for circles; default is the nam-file)
ula, lau: File of the same structure but saved as Unicode text.
filter
Filter data set. Format of the filter dataset; description aside.
filterW
Weight data set (usually with extension ".wgt"); description aside. Normally, the absolute population number form the weights.
hinumgeo
Maximum number of geometry files (5)
geoorder
Order of the geometry datasets how they appear on the menu (1, 2, 3, 4, ....).
geoexclude
Geometry datasets may be excluded from the menu. Example: (1, 2) = do not include geo1 and geo2).
 
 

Data

data, txtdat
Dataset name of a delimited text dataset (delimiters: tabs, semicolon) with extension ".txt"; may end in "txt.gz" - compressed data; first row contains variable names. Data in clipboard has to be in the same format. txtdat is a variant of this parameter without the need of a "txt" extension (NB: blanks are no longer accepted as delimiters; missing values: empty "cells" or any string which can not be translated to a number).
vnm / uvn / vnu
Additional information about the variables (in the same order as the variables appear in the data file. Tabulator delimited are the following items (one variable per record):
variable name<tab>data type<tab>data units<tab>long data units

variable name
(may not be the same as in the data file but a longer one)
data type
: relative or absolute values (r / a). With relative values it is no possible to create cartograms; absolute values are used to make cartograms, they are visualized by areal density values.
data units
: e.g. "%" (appears in information windows) ("")
long data units
: e.g. "[per capita]" (appears below the legend) (=data units)
 
uvn, vnu: File of the same structure but saved as Unicode text.
 
geoparts
If the geo dataset consists of different kind of areal units (example follows, e.g. a map with 171 communes, a smaller map of 11 districts and another with the whole canton) this parameters is important for the construction of cartograms and the calculation of statistics. It consists of pairs with nobs/areal weight (in the case obove: value="171, 1.0, 11, 0.2, 1, 0.05").
 
dataorder
Order of the variables how they appear on the menu (1, 2, 3, 4, ....). All *-parameters refer to the original order in the dataset.
 
datahidden
List of variables that don't appear in the popup-menu (but in the cartogram dialogs). All *-parameters refer to the original order in the dataset.
 
exclude / dataexclude
Variables may be excluded from the popup menu. Example: (1, 2) = do not include the first two variables; (-1, -2) = do not include the last two variables. The numbers refer to the original order (before sorting by "dataorder").
 
digits*
Number of digits after the decimal point (1)
links
URL or relative path of links appearing in the data dialog (when you click on the map). Format and example for a link file: one URL per record.
linktext
Short text at the link, in the example below: "See details at:"
 

 

Themes (from version 1.3b65 onwards)
Themes appear in a special menu ("Themes"). hinumtheme defines the maximum number of themes to read in. The names of the themes are definied by theme*, the attached textfiles with themedat*. The default delimiter (themedelim) is the underscore character. Most of the *-parameters can then be defined, e.g. as: colors (default colors), colors_3 (default colors for theme 3), colors_2_7 (color for variable 7 of theme 2).
The theme feature is not yet finished.
 
firsttheme
Theme selected at startup. (1)
firstvar_*
Variable selected at startup of a theme, e.g. firstvar_2=4: in theme 2 starts with the 4th variable. (1)
firstgeo_*
Geometry selected at startup of a theme, e.g. firstgeo_3=2: in theme 3 starts with the 2nd geometry. (1)
 
 

Symbolization

 

 
digits*
Number of digits after the decimal point (1)
mtyp*
Type of symbolization: 1: continuously from "bright to dark", 2: continously from "bright" to "mbright" and form "mdark" to "dark"; 3: nominal values. Use lookup to assign colors to values. (1; variant: coltype). New: mtyp=12: automatic selection of a colorscheme: if zmin<0 and zmax>0: mtyp=2; else mtyp=1.
 
color1scheme*
Number of color scheme for sequential colors, mtyp=1. (100 to 118);
color2scheme*
Number of color scheme for divergent colors, mtyp=2. (200-209, 401-420, 501-512)
 
color3scheme*
Number of color scheme for nominal colors, mtyp=3. (300 to 308)
 
classes* (bottom, medium, top)
The 3 "class" values; Defaults: ([mean - factor_s * standardDeviation], [mean], [mean + factor_s * standardDeviation])
factors*
factor_s defines the width of the intervall between bottom and top (cf. classes). If factors is negative (e.g. -2.5) bottom and top lay at percentiles (2.5% of the values are below bottom and 2.5% are above top). (1.5)
colors* (white, bright, dark, black, missing, background, border, text)
Colors of the first color scheme (#ffff64, #ffff00, #ff0000, #a00000, #deffde, #dedeff, #000000, #000000: yellow to red)
bicolors* (white, bright, mbright, mdark, dark, black, missing, background, border, text)
Colors of the second color scheme (#a00000, #c70000, #debebe, #bedebe, #00aa00, #009600, #ffffff, #f6f6f6, #000000, #000000: red to reddish gray and greenish gray to green)
eyeexp*
Parameter for the transition from bright to dark
background* / bibackground* / nomibackground*
Color of the map background for the 3 color schemes (#dedeff / #f6f6f6)
text* / bitext* / nomitext*
Color of the legend text (#000000 / #000000)
fehlend* / bifehlend* / nomifehlend*
Color of the areas with missing values (#ffdeff / #ffffff)
border* / biborder* / nomiborder*
Color of the polygon boundaries (#000000 / #000000)
withborders*
Areal units with or without border lines (0 / 1)
lookup*
Feature for nominal data: Triples of number, legend text, and color. Example: <param name="lookup5" value="1,low, #4400c7,2,medium, #069696,3,high, #c70044">: the 5th variable consists of the values 1, 2, and 3. "1" means "low" and gets a blue color. Values with no explicitly defined color get random colors and do not appear in the legend (as such with the name starting with "$$").
calibration*
Defining the size of the circles (in the case of absolute values); 2 variations:

(value / radius / bias / exponent / minval): An areal unit with a value of "value" becomes a circle with radius "radius". Values lower then "minval" were not drawn. Area proportional symbols get an exponent of 2.0, a variant could be 3.0 (cubic). Bias: A value which is added to the value of each areal unit.

(-percentage / bias / exponent / minval)
If the first parameter value is negative, the total area of all circles covers about "percentage" of the map.
(-30.0).

Feature (de)activation

bitri
Experimental feature for the creation of bi- and trivariate maps (0 / 1)
withlabels
Labels in circles (0 / 1)
polylabels
Labels over polygons (0 / 1); in an experimental stage (no conflicts wer resolved)
zoomtool
-1: zoom tools activated but initially not visible / 0: no zoom tools / 1: activated and initially visible
pasteField
Small field where own data values can be pasted in (0 / 1)
EPSMenu
Export of the map as EPS data (appears in a separate window) (0 / 1). Details
psctMenu
Export of the geometry in ArcInfo Generate format (written to the console) (0 / 1)
reloadMenu
Option to reload newer data form the web server (0 / 1)
writeParamMenu
Export of some main parameters (e.g. changed colors) to the java console (0 / 1)
tipWindowMenu
Experimental feature of small tip windows (0 / 1)
 

Other

splash
Name of an alternative splash screen (splash.gif)
 

Special characters

For the use in the files nam and vnm some special characters can be inserted (e.g. "Z$urich" gives "Zürich"):

  
$a ä    $A Ä    $b à    $f á    $n â   
$d ç   
$m ë           $g è    $e é    $c ê   
$j ï                  $s í    $i î   
$w ñ    $W Ñ   
$o ö    $O Ö           $q ó    $t ô   
$u ü    $U Ü    $p ù    $r ú    $v û   
$2 2 (small exponent)    $3 3   
$% ‰ (per thousand)   
$< «    $> »   
$. '    $: "    $$ $   
\n (new line)

Layers

In order to add elements like rivers, lakes, geometric forms, other boundaries etc. there is a layer concept. The layer parameter consists of a sequence number and a layer type and other description parameters.

layer*
The number (layer1, layer2, etc.) has no meaning but they have to be distinct.
  • Sequence number. The layers were painted in the order of this number. By default the thematic map is on level 0, the legend on level 1 (just above the map). Layers below the thematic map get a negative number, layers above a number > 1. You can change also the postion of the map and the legend.
  • Layer type. At the moment the following types are supported:
    • 1: Legend (default: sequence=1)
    • 2: "normal" geometries, as .psc or .cir
    • 5: rectangle in world coordinates
    • -5: rectangle in screen coordinates
  • Fillcolor (not for legends)
  • Bordercolor (not for legends)
  • Line thickness (in test stage, at the moment just for polygon geometries), values: 0, 2, ... 9; The numbers define one pixel shifts, e.g. 25, 2457, 12345678 (25: the geometry is drawn three times: in original position, one pixel above and one pixel to the right).

    1 2 3
    4 5
    6 7 8

Examples:

<param name="layer1" value="-12,2,geometry/ch_lakes.psc, #111111, #222233,25">
<param name="layer5" value="13,-5,2, 2, 50, 60, #ff8800, #005500">
<param name="layer3" value="56,5,674244.3,228901.31,711900.8,278332.47, #0000dd, #ffff00">
<param name="layer4" value="88,1">
<param name="layer2" value="93,2,geometrie/zh_182.cir,none, #000000">

Error and Message Codes

See list of codes.


 

Deprecated, for compatibility to older versions

infolevel
Level of debug messages (0: no msg / 9999: many).
data*
Dataset name
ownbtn
Offers a text field where you can paste your own data values (0, 1).
reloadbtn
Reload (actualized) data values (0, 1). We use this feature during the counting out of votation results with updated data on the server every quarter of an hour.
adjustbutton
Rezize map to window size (not possible as applet in a browser) (0, 1)
geobase
URL or relative path of the geometry ("none": documentbase)
symbolbtn
Brings up a dialog to change colors and class values (0, 1). Clicking into the legend area does the same.
 
hinum
Maximum number of variables (50). In the now prefered case of txt-files this number is automatically set to the number of read variables.
 
top
values > top: color black
bottom
values < bottom: color white
bright - dark
values between bottom and top: color between the colors bright and dark
eyeexp
parameter for the transition from bright to dark
missing
color for areal units with missing values.
panelnorth
The panel with all these buttons, fields and pop-up-menus is below (0) or above (1) the map.
filterbtn
Add a button to do a simple thematic generalizaton by a polygon filtering (0, 1).
carto
Add a button for the construction of a areal unit cartogram (0, 1). There must be a suited variable with absolute values.
psbtn
Add a button for writing an EPS file to the java console (0, 1).

 

 

.psc format

This is a compact format for polygon boundaries. It can easily be derived from ArcInfo shapefiles (using the Java application shp2psc). It is recommended to use .psc instead of .shp.

.cir format

It has the following structure: 1st row: number of observations; 2nd to (nobs+1)th row: ID / x / y / radius (tab delimitted).

Example:

171
1•667327.4•223303.5•1191.0
2•668476.4•227875.7•3048.0
3•661933.4•228675.1•1882.7
...
261 679560.8 242579.1 18159.9

.cxy format

It has the following structure: 1st row: number of observations; 2nd to (nobs+1)th row: ID / x / y (tab delimited). These coordinates are used for graduated circle symbol maps.

Example:

182
1•679692•237256
2•676443•238036
3•677557•240977
...
272•685795 250878

.nam / .lab format

Unicode variants: .nau, .una / .lau, .ula

Names of the areal units, one (or two) per row in the same sequence as the polygons or circles. If there is a second name (after a tab), only the second column names appear as polygon labels.

Example:
Aeugst
Affoltern•Aff.
Bonstetten
...
Stadt Z$urich•Z$urich

.link format

URL for each areal unit, one per row in the same sequence as the names, polygons or circles. Use "none" if there is no link for a specific area.

Example:
none
http://www.affoltern-am-albis.ch
http://www.bonstetten.ch
...
http://www.stadt-zuerich.ch

.vnm / .vnu / .uvn format

variable name<tab>data type<tab>data units<tab>long data units

Example:
Vorlage•r•%•Anteil Ja-Stimmen Persons•a• •number of persons\nCensus 2000

.fil format

For each boundary:
number of areal unit on one side;
number of areal unit on the other side;
length of common boundary (tab delimitted). Please note: we use a serial number of the areal units and not the IDs. Borders to lakes or to polygons outside the covered region may have the same number for the to adjacent polygons.

Example:

1 2 3773.99738
1 9 2648.35318
1 12 115.0252
2 2 1345.30548
2 9 2999.51607
...
171 167 1613.47709
-999

(A provisional documentation for a 2 step process (ArcInfo + Excel) is here).

.wgt format

It has the following structure: 1st row: number of observations; 2nd to (nobs+1)th row: ID / weight of unit ID (tab delimitted).

Example:

171
1•1542
2•10258
3•4165
...
261 340402

Generate format

(output format)

Polygons as Lines
The output consists of a series of sections which start with a numeric ID on a line by itself, followed by 2 or more lines with X,Y coordinate pairs, finishing with the word "end" on a line by itself. This pattern may repeat as many times as necessary. The end of the output is indicated by the word "end" on a line by itself immediately after the "end" of a line section.
Circles as Points
The output consists of one or more lines, each of which has an ID number followed by a pair of coordinates. It ends with the word "end" on a line by itself.

 


Color Schemes

Find here the codes for the color schemes (adapted from Cinty Brewer).

 

Additional color examples

 

<param name="bicolorsX" value="#008855, #339900, #e0ff00, #ffff33, #ff0000, #c80000">

 

<param name="bicolorsX" value="#d4ffa7, #fcfc4b, #b45703, #b45703, #702103, #500101">

 

<param name="bicolorsX" value="#d4ffa7, #fcfc88, #ff2200, #ff0000, #700040, #5e005e">

 

<param name="bicolorsX" value="#000099, #0000cc, #c0e8ff, #ffcccc, #ff0000, #dd0000">

 

<param name="bicolorsX" value="#026e03, #017906, #65fcd1, #9cf4fc, #590169, #400555">