We propose refining the NTL classification in GEEST to better reflect local conditions, particularly for small island countries. Instead of using fixed thresholds or coverage percentages, we'll employ local statistics to create a more contextually relevant classification. This approach is supported by Elvidge et al. (2013), who emphasize the importance of considering local context in night-time light analysis.
- Clip the global NTL raster to the country boundary.
- Calculate statistics for the clipped raster: min, max, mean, median, and 75th percentile.
- The use of percentiles in NTL analysis is supported by Levin & Zhang (2017).
- Apply the classification scheme based on local statistics.
GEEST Class | Description | NTL Value Range |
---|---|---|
0 | No Access | 0 - 0.05 |
1 | Very Low | > 0.05 - 0.25 * Median |
2 | Low | > 0.25 * Median - 0.5 * Median |
3 | Moderate | > 0.5 * Median - Median |
4 | High | > Median - 75th percentile |
5 | Very High | > 75th percentile |
This classification approach aligns with the methods used by Chen & Nordhaus (2011) in using luminosity data as a proxy for socio-economic factors.
For implementation in QGIS, use the Raster Calculator with the following expression:
(NTL <= 0.05) * 0 +
(NTL > 0.05 AND NTL <= [0.25 * median]) * 1 +
(NTL > [0.25 * median] AND NTL <= [0.5 * median]) * 2 +
(NTL > [0.5 * median] AND NTL <= [median]) * 3 +
(NTL > [median] AND NTL <= [75th_percentile]) * 4 +
(NTL > [75th_percentile]) * 5
Replace [median]
and [75th_percentile]
with the actual calculated values.
Here's a simple Python script to calculate the required statistics for a GeoTIFF raster:
import rasterio
import numpy as np
def calculate_raster_stats(raster_path):
with rasterio.open(raster_path) as src:
data = src.read(1)
data = data[data != src.nodata] # Remove no data values
min_val = np.min(data)
max_val = np.max(data)
mean_val = np.mean(data)
median_val = np.median(data)
percentile_75 = np.percentile(data, 75)
return {
'min': min_val,
'max': max_val,
'mean': mean_val,
'median': median_val,
'75th_percentile': percentile_75
}
# Usage
raster_path = 'path/to/your/iso3_ntl.tif'
stats = calculate_raster_stats(raster_path)
print(stats)
This script can be integrated into the GEEST QGIS plugin to automatically calculate the statistics needed for the classification.
Benefits:
- Adapts to local lighting conditions
- Provides meaningful classification for areas with varying NTL intensities
- Maintains consistency with the original GEEST approach while improving granularity
If the NTL values within the Area of Interest (AOI) are predominantly or entirely below 0.05, which is our baseline for electricity access, we need to adjust our approach. Here's how to proceed:
-
Check the data range: After clipping the NTL raster to our AOI, examine the statistics, particularly the maximum value.
-
If max value < 0.05:
- This indicates that the entire area falls below our standard threshold for electricity access.
- In this case, we need to create a relative scale based on the available data. This approach is informed by Small et al. (2005), who discuss methods for analyzing areas with low light emissions.
-
Adjusted classification for low-value areas: Use this modified classification scheme based on the local maximum value:
GEEST Class | Description | NTL Value Range |
---|---|---|
0 | No Light | 0 |
1 | Very Low | > 0 - 0.2 * max_value |
2 | Low | > 0.2 * max_value - 0.4 * max_value |
3 | Moderate | > 0.4 * max_value - 0.6 * max_value |
4 | High | > 0.6 * max_value - 0.8 * max_value |
5 | Highest | > 0.8 * max_value - max_value |
This adaptive thresholding approach is conceptually similar to methods described by Otsu (1979) for image classification.
For implementation in QGIS, use the Raster Calculator with the following expression:
with_variable('max_val', maximum("NTL@1"),
(NTL = 0) * 0 +
(NTL > 0 AND NTL <= @max_val * 0.2) * 1 +
(NTL > @max_val * 0.2 AND NTL <= @max_val * 0.4) * 2 +
(NTL > @max_val * 0.4 AND NTL <= @max_val * 0.6) * 3 +
(NTL > @max_val * 0.6 AND NTL <= @max_val * 0.8) * 4 +
(NTL > @max_val * 0.8) * 5
)
Note: Replace "NTL@1" with our actual raster layer name.
It's important to note that NTL data can vary seasonally and annually. As Xie et al. (2019) demonstrate, temporal variations in artificial nighttime lights can provide insights into urbanization patterns and socio-economic changes. For GEEST, consider using multi-year averaged NTL data to mitigate short-term fluctuations and capture more stable patterns of lighting infrastructure.
Users of this enhanced NTL classification in GEEST should be aware of certain limitations:
- Overglow Effect: NTL data can suffer from the "overglow" effect, where light appears to extend beyond its actual source (Small et al., 2005). This may lead to overestimation of lit areas in some regions.
- Saturation in Urban Centers: In highly urbanized areas, NTL sensors may saturate, leading to a loss of differentiation in the brightest areas (Elvidge et al., 2013).
- Rural Underrepresentation: In sparsely populated or rural areas, the resolution of NTL data may not capture small-scale lighting infrastructure adequately.
Clear visual representation of the decision-making process in the classification of NTL data, accounting for different scenarios based on the data characteristics.
graph TD
A[Download NTL data] --> B[Gunzip data]
B --> C[Clip using country boundary]
C --> D[Check max_value]
D -->|max_value > 0.05| E[Check median and 75th percentile]
D -->|max_value <= 0.05| F[Use modified classification scheme]
E -->|Difference > 5% of max_value| G[Use original classification scheme]
E -->|Difference <= 5% of max_value| F
G -->|Use median and percentile| H[Classify NTL data]
F -->|Use max_value| H
H --> I[Output classified NTL map]
style A fill:#f9f,stroke:#333,stroke-width:2px
style B fill:#bbf,stroke:#333,stroke-width:2px
style C fill:#bbf,stroke:#333,stroke-width:2px
style D fill:#fbb,stroke:#333,stroke-width:2px
style E fill:#fbb,stroke:#333,stroke-width:2px
style F fill:#bfb,stroke:#333,stroke-width:2px
style G fill:#bfb,stroke:#333,stroke-width:2px
style H fill:#fbf,stroke:#333,stroke-width:2px
style I fill:#ff9,stroke:#333,stroke-width:2px
This diagram illustrates the process as follows:
- Download the NTL data from the provided URL.
- Gunzip the downloaded data.
- Clip the data using the country boundary.
- Check the max_value of the clipped NTL data.
- If max_value > 0.05:
- Check if the median or 75th percentile is within 5% of the max_value.
- If the difference is > 5% of max_value, use the original classification scheme (median and percentile based).
- If the difference is <= 5% of max_value, use the modified classification scheme.
- If max_value <= 0.05:
- Use the modified classification scheme directly.
- Classify the NTL data using the selected scheme.
- Output the classified NTL map.
- Elvidge, C. D., Baugh, K. E., Zhizhin, M., & Hsu, F.-C. (2013). Why VIIRS data are superior to DMSP for mapping nighttime lights. Proceedings of the Asia-Pacific Advanced Network, 35(0), 62. https://doi.org/10.7125/APAN.35.7
- Levin, N., & Zhang, Q. (2017). A global analysis of factors controlling VIIRS nighttime light levels from densely populated areas. Remote Sensing of Environment, 190, 366–382. https://doi.org/10.1016/j.rse.2017.01.006
- Small, C., Pozzi, F., & Elvidge, C. D. (2005). Spatial analysis of global urban extent from DMSP-OLS night lights. Remote Sensing of Environment, 96(3-4), 277-291. https://doi.org/10.1016/j.rse.2005.02.002
- Chen, X., & Nordhaus, W. D. (2011). Using luminosity data as a proxy for economic statistics. Proceedings of the National Academy of Sciences, 108(21), 8589-8594. https://doi.org/10.1073/pnas.1017031108
- N. Otsu, "A Threshold Selection Method from Gray-Level Histograms," in IEEE Transactions on Systems, Man, and Cybernetics, vol. 9, no. 1, pp. 62-66, Jan. 1979, https://doi.org/10.1109/TSMC.1979.4310076
- Xie, Y., Weng, Q., & Fu, P. (2019). Temporal variations of artificial nighttime lights and their implications for urbanization in the conterminous United States, 2013–2017. Remote Sensing of Environment, 225, 160-174. https://doi.org/10.1016/j.rse.2019.03.008