## 3 Materials and Methods
### Data
The multi-facetted plot of the individual bands of the Landsat OLI/TIRS image has been plotted using libraries 'raster' and 'terra' (version 1.2.11), by the code in Listing 3. Here the case is given for the image covering Basoko (2022), applied for other scenes. Figure 4: Composite of monochrome 11 bands: Landsat-8 OLI/TIRS C1 for Basoko region (Arowumi and Congo rivers). Multi-spectral image ‘LC81770592022039 LGN00’: ultra blue (B1), blue (B2), green (B3), red (B4), near infrared (NIR) (B5), shortwave infrared (SWIR) 1 (B6), shortwave infrared (SWIR) 2 (B7), panchromatic (B8), cirrus (B9), thermal infrared (TIRS) 1 (B10), TIRS2 (B11). Plotting: R.  
```
1 network(/Users/poliamlemenkova/Documents/Rf53_UC_k_means/Bumba_LC08_LITP_178058_20131223_20200912_02_T1\")
2#Importingdata
3 Landsat_Bumba2013<list.files(/Users/poliamlemenkova/Documents/Rf53_UC_k_means/Bumba_LC08_LITP_178058_20131223_20200912_02_T1\")
4#Printingthelist
5 list.files()
6#creatingSpatRasterobject
7 landsat<=fast(Landsat_Bumba2013)
8#checkproperties
9 landsat
10#combiningbandsfornaturalcolourcomposite,hereusingbands4,3 and2. 11 landsatRGB<-landsat[[(c4,3,2)]]
12#checkupmetadata
13 landsatRGB
14#visualisingnaturalcolourcompositeonscreen
15 plotRGB(landsatRGB,r=1,g=2,b=3,axes=FALSE,stretch=\"lin\")
16#plotingandsayingthefile
17 plot(landsRGB,g=colors,font.main=1,main=NDVIforLandsat-8 OLI/TIRSC1 image
18 LLITP_178058_20131223_20200912_02_T1_Bumba, Congo\",cex.main=0.9,axes=FALSE)
19#combiningbandsforfalsecolourcomposite,hereusingbands5,4 and3. 20 landsatFC<-landsat[(c4,3,4)]
21#visualisingfalsecolourcompositeonscreen
22 plotRGB(landsatFC,r=1,g=2,b=3,axes=FALSE,stretch=\"lin\")
23#plotingandsayingthefile
24 plot(landsatRGB,col=colors,font.main=1,main=NDVIforLandsat-8 OLI/TIRSC1 image
25 LITP_177059_20131216_20200912_02_T1_B: Basoko, centralCongo\",cex.main=0.9,axes=FALSE)
```  
Listing 3: R code used for the monochrome individual bands of the image Landsat OLI/TIRS. ```
1 library(raster)
2 library(rstra)
3#Setupworkingdirectory
4 setwd(/Users/poliamlemenkova/Documents/Rf53_UC_k_means/Basoko_LC08_LITP_177059_20220208_2022022_02202_0222_0221_022_T1\")
5b1<-rast('L08_LITP_177059_20220208_202202212_02_T1_



Figure 5: Natural (bands 4-3-2) and false colour (bands 5-4-3) composites of the Landsat 8 OLI/TIRS image for the three target areas: Bumba, Basoko and Kisangani. Mapping: RStudio. (**a**) Bumba: natural colour composite, 2013. (**b**) Bumba: false colour composite: 2013. (**c**) Basoko: natural colour composite: 2013. (**d**) Basoko: false colour composite: 2013. (**e**) Kisangani: Natural colour composite: 2013. (**f**) Kisangani: False colour composite: 2013. The above-demonstrated scripts show the key advantage of R, which consists of the optimization of the workflow of remote sensing data processing. Moreover, it illustrates its advanced analysis capabilities aimed at processing raster data by scripting. Scripts can be re-used with modified lines of code for the next images as a consecutive work, rather than repeated as a whole process of image analysis for each image, as in GIS, which is a fundamentally different approach compared to GIS. This is especially true for processing big Earth observation data, which play a key role in geoscience. The rapid development of remote sensing technologies has resulted in an increased amount of available satellite images, which requires advanced technologies for processing these large massits of spatial data. In contrast to the traditional software, programming languages provide an effective solution to handle such volumes of spatial data by scripting. R, as an example of a high-level programming language, effectively solves the problem of the optimization of image processing. ### K-Means Clustering

The k-means clustering of the R package RasterStack is a method by which pixels are assigned to spectral classes by machine-based partitions without prior knowledge of those classes. It is a straightforward way to produce a map of land cover classes using an automatic approach to image classification.