The event layer displays the geographical location of events registered in the DHIS2 tracker. Provided that events have associated coordinates, you can use this layer to drill down from the aggregated data displayed in the thematic layers to the underlying individual events or cases.
You can also display aggregated events at the facility or at the boundary level. You do this through a thematic layer using event data items. This is useful when you only have the coordinates for the Org Unit under which the events are recorded.
Event layers are represented by layer cards in the layer panel such as:
Along the top of the event card from left to right are:
A grab field to allow dragging and re-ordering layers with the mouse
The title and period associated with the layer
An arrow symbol to collapse and expand the event card
In the middle of the event card is a legend indicating the styling of the layer.
Along the bottom of the event card from left to right are:
An edit (pencil) button to open the layer configuration dialog
An eye symbol for toggling the visibility of the layer
A slider for modifying the layer transparency
A more actions (three dots) button with additional options:
Download data allows you to download the data for this layer in GeoJSON format for use in other mapping software
Edit layer is the same as edit button above
Remove layer will remove this layer from the current map.
To create an event layer, choose Events on the Add layer selection. This opens the Events layer configuration dialog.
In the DATA tab:
Select a program and then select a program stage. The Stage field is only shown once a program is selected.
If there is only one stage available for the selected program, the stage is automatically selected.
Select a value from the Coordinate field for the positions shown on the map. By default, “Event location” is selected. Depending on the data elements or attributes that belong to a program, other coordinates such as “Household position” are available.
In the PERIOD tab
select the time span for when the events took place. You can select either a fixed period or a relative period.
In the Period field, select Start/end dates and fill in a start date and an end date.
In the Period field, select one of the relative periods, for example This month or Last year .
In the FILTER tab:
Click ADD FILTER and select an available data item to add a new filter to the data set.
For data item of type option set , you can select any of the options from the drop down box by using the down-wards arrow or by start typing directly in the box to filter for options.
For data item of type number , you can select operators like equal, not equal, greater than or less than.
For data item og type boolean (yes/no), you can check the box if the condition should be valid or true.
For data item of type text you will get two choices: Contains implies that the query will match all values which contains your search value, and Is exact implies that only values which is completely identical to your search query will be returned.
Multiple filters may be added. Click the trash button on the right of the filter to remove it.
In the ORG UNITS tab:
Select the organisation units you want to include in the layer. It is possible to select either
One or more specific organisation units, or
A relative level in the organisation unit hierarchy, with respect to the user. By selecting a User organisation unit the map data will appear differently for users at different levels in the organisation unit hierarchy.
In the STYLE tab:
Select Group events to group nearby events (cluster), or View all events to display events individually.
Select a color for the event or cluster points.
Select the radius (between 1 and 20) for the events.
Select Show buffer to display visual buffer around each event. The radius of the buffer can be modified here. This option is only available if you select View all events above.
Select a Style by data element to colorise the events according to a data value. The options varies for different data types:
Option sets : Select a color for each option in an option set. You can set default colors for an option in the Maintenance app.
Numbers : You can style a numeric data element in the same way as thematic layers using automatic or predefined legends.
Booleans : Select a color for true/yes and another for false/no.
Click ADD LAYER .
In the layer panel, click the edit (pencil) icon on the event layer card.
Modify the setting on the DATA, PERIOD, FILTER, ORG UNIT and STYLE tabs as desired.
Click UPDATE LAYER .
For events in a cluster map, you can modify the information displayed in the event pop-up window.
Open the Programs / Attributes app.
Click Program .
Click the program you want to modify and select View program stages .
Click the program stage name and select Edit .
Scroll down to the Selected data elements section.
For every data element you want to display in the pop-up window, select corresponding Display in reports .
Click Update .
The raw data for event layers can be downloaded in GeoJSON format for more advanced geo-analytics and processing in desktop GIS software such as QGIS . The downloaded data includes all individual events as GeoJSON features, including attributes for each data element selected for Display in reports .
In the layer card to the left, click the more actions (three dots) icon and then on Download data
Select the ID format to use as the key for Data Element values in the downloaded GeoJSON file. There are three options available:
Select whether or not to Use human-readable keys for other Event attributes, such as Program Stage, Latitude, Longitude, Event Data, and Organization Unit ID, Name, and Code. When this option is not selected these values will be the computer-friendly ID instead of the human-readable (and translated) name.
Click the DOWNLOAD button to generate and download a GeoJSON file. The data will be requested from the DHIS2 server and processed by the maps application. This operation may take several minutes to complete.
Once the GeoJSON file has been downloaded it can be imported into most standard GIS software applications.
Note that the downloaded data does not include style information as it is not natively supported by the GeoJSON format. Styles can optionally be recreated in external GIS applications using the attributes of each feature.
To clear all event layer data in a map:
In the layer card to the left, click the more actions (three dots) icon and then on Remove layer .
The layer is removed from the current map.