Service API
Address
POI
Route
Map
Indoor
Dynamic Information
Campaign
Demography
Traffic
User Data
Risk
Analysis
- Spatial Analysis
- Add Service Area
- Add Buffered Line To User Region
- Add Buffered Route To User Region
- Add Route To User Line
LocationBox API
Click to see the Analysis API.
LocationBox Map Coloring is capable of using city or town boundaries as coloring regions.
Type of the region must be specified while creating the coloring analysis.
createColoringAnalysis method takes two attributes as input;
createColoringAnalysis(typ, sym, mouseclick)
typ is the type of the region and takes four different values.
BOLGE -- (Province) Takes a value between 1 and 7.
IL -- (City) See Address Elements
ILCE -- (Town) See Address Elements
MAHALLE -- (District) See Address Elements
BOLGE values;
1 -- Marmara
2 -- Karadeniz
3 -- Dogu Anadolu
4 -- Guneydogu Anadolu
5 -- Akdeniz
6 -- Ege
7 -- Ic Anadolu
See Advanced Coloring Analysis Demo for more information on sym attribute.
See Map Coloring Demo for more information on mouseClick.
var analysis = new IAnalysis();
analysis.createColoringAnalysis("IL", mouseClick);
Creating a coloring analysis is basicly visualising tabular data. The analysis data must be properly formatted in order to be shown on a map coloring. Make sure that you use correct tags to form your table of data.
var xml = "<table>"+
"<tr><th>IL</th><th>COLOR</th><th>INFO-1</th><th>INFO-2</th></tr>"+
"<tr><td>typ id</td><td>color id</td><td>info-1 value</td><td>info-2 value</td></tr>"+
"<tr><td>typ id</td><td>color id</td><td>info-1 value</td><td>info-2 value</td></tr>"+
...
"<tr><td>typ id</td><td>color id</td><td>info-1 value</td><td>info-2 value</td></tr>"+
"</table>";
There are 7 basic colors and "transparent" option is available. Each color has 10 shades.
var xml = "<table>"+
"<tr><th>IL</th><th>COLOR</th><th>INFO-1</th><th>INFO-2</th></tr>"+
"<tr><td>34</td><td>1</td><td>2</td><td>3479</td></tr>"+
"<tr><td>42</td><td>2</td><td>3</td><td>4956</td></tr>"+
"<tr><td>35</td><td>3</td><td>4</td><td>32372</td></tr>"+
"<tr><td>23</td><td>4</td><td>5</td><td>3</td></tr>"+
"<tr><td>9</td><td>5</td><td>6</td><td>223</td></tr>"+
"<tr><td>48</td><td>6</td><td>7</td><td>123</td></tr>"+
"<tr><td>44</td><td>7</td><td>8</td><td>22</td></tr>"+
"<tr><td>55</td><td>3</td><td>9</td><td>1</td></tr>"+
"</table>";
analysis.setAnalysisColoringData(xml);
LocationBox Pie Analysis enables creating analyses using city or town boundaries as regions with infinite number of parameters colored by infinite number of color shades.
Type of the region must be specified while creating the pie analysis.
createPieAnalysis method takes two attributes as input;
createPieAnalysis(typ, mouseclick)
typ is the type of the region and takes four different values.
BOLGE -- (Province) Takes a value between 1 and 7.
IL -- (City) See Address Elements
ILCE -- (Town) See Address Elements
MAHALLE -- (District) See Address Elements
BOLGE values;
1 -- Marmara
2 -- Karadeniz
3 -- Dogu Anadolu
4 -- Guneydogu Anadolu
5 -- Akdeniz
6 -- Ege
7 -- Ic Anadolu
See Pie Analysis Demo for more information on mouseClick.
var analysis = new IAnalysis();
analysis.createPieAnalysis("IL", mouseClick);
Style of the pie analysis is defined by a json object.
var sty = { "radius": radius,
"pies": [ {"name": "name 1", "color": "hexadecimal color value"},
{"name": "name 2", "color": "hexadecimal color value"},
...
{"name": "name n", "color": "hexadecimal color value"} ]
};
var sty = { "radius": 20, "pies": [ {"name": "A", "color": "#FF0000"},
{"name": "B", "color": "#00FF00"},
{"name": "C", "color": "#0000FF"} ]
};
analysis.setAnalysisPieStyle(sty);
Creating a pie analysis is basicly visualising tabular data as a pie graph. The analysis data must be properly formatted in order to be shown on a pie analysis. Make sure that you use correct tags to form your table of data.
var xml = "<table>"+
"<tr><th>IL</th><th>Item 1</th><th>Item 2</th> ... <th>Item n</th></tr>"+
"<tr><td>typ id</td><td>Item 1 value</td><td>Item 2 value</td> ... <td>Item n value</td></tr>"+
"<tr><td>typ id</td><td>Item 1 value</td><td>Item 2 value</td> ... <td>Item n value</td></tr>"+
...
"<tr><td>typ id</td><td>Item 1 value</td><td>Item 2 value</td><td>Item n value</td></tr>"+
"</table>";
Number of items to be used in the pie analysis are not limited but too many items may prevent the analysis to give a clear demonstration.
var xml = "<table>"+
"<tr><th>IL</th><th>Item 1</th><th>Item 2</th><th>Item 3</th></tr>"+
"<tr><td>35</td><td>500.0</td><td>200.0</td><td>1000.0</td></tr>"+
"<tr><td>23</td><td>300.0</td><td>500.0</td><td>100.0</td></tr>"+
"<tr><td>55</td><td>1500.0</td><td>800.0</td><td>600.0</td></tr>"+
"<tr><td>1</td><td>500.0</td><td>200.0</td><td>1000.0</td></tr>"+
"</table>";
analysis.setAnalysisPieData(xml);