Published September 30, 2022 | Version v1
Book Open

R-scripts for Generation of 5, 8 and 16 Random Sampling Points Within Predefined Rectangles

  • 1. Canadian Soil Information Service (CanSIS)

Description

Source web page: https://www.globalgeochemicalbaselines.eu/content/185/ebook-r-scripts-for-generation-of-5,-8-and-16-random-sampling-points-/

SYNOPSIS

The Global Geochemical Reference Network consists in total of 19,833 grid cells of 160x160 km that cover the whole globe. The land surface of the Earth is covered by 7356 grid cells (Global Terrestrial Network, GTN), and the marine surface by 12,477 grid cells (Global Marine Network, GMN). Planning the sampling campaigns in both realms requires the generation of random sampling points within each of the 160x160 km grid cell. For this purpose, three R-scripts were written for the generation of 5-, 8- and 16-random sampling points within each 160x160 km grid cell. The three R-scripts can be used to generate random sampling points within any other size rectangular grid cell. This publication provides the instructions for using the three R-scripts, the format of the input and output files, and the availability of the executable files, as well as the output files, from the website of the IUGS Commission on Global Geochemical Baselines.

The URL of the pdf file is: https://www.globalgeochemicalbaselines.eu/datafiles/file/He_Geng_2022_IUGS-CGGB_R-scripts_for_generation_of_5-8-16_random-sampling-points.pdf.

Supplementary material: The following files can be downloaded from different web pages of the IUGS Commission on Global Geochemical Baselines:-

(a) Executable R-scripts:

  • randomSampling5PointsOnGrids.R (R script for the generation of 5 random points).
  • randomSampling8PointsOnGrids.R (R script for the generation of 8 random points).
  • randomSampling16PointsOnGrids.R (R script for the generation of 16 random points).

The source code of the 5, 8 and 16 random sampling points are in Appendices 1, 2 and 3, respectively.

The three executable R-scripts for the generation of 5-, 8- and 16-random points in predefined rectangles over the terrestrial and marine surfaces are in a zip file:

IUGS-CGGB_R-scripts_Generation_5-8-16_random_points.zip’, which can be downloaded from the ‘Publications/Software Programs’ web page.

(b) Global Reference Network grid cells of 160x160 km files:

  • IUGS-CGGB_19833_GRN_160x160km_grid_cells.xlsx (Microsoft™ Excel workbook file with the 19,833 grid cells of the Global Reference Network each of 160x160 km).
  • IUGS-CGGB_GRN_19833_160x160km_grid_cells.zip (same as above but in a Google Earth kml file format). When unzipped the file name is: IUGS-CGGB_19833_GRN_160x160km_grid_cells.kml.

The above two files can be downloaded from the ‘Sampling/GTN 160x160 km’ web page.

(c) Global Terrestrial Network grid cells of 160x160 km files: 

  • IUGS-CGGB_7356_GTN_160x160km_grid_cells.xlsx (Microsoft™ Excel workbook file with the 7356 grid cells of the Global Terrestrial Network each of 160x160 km).
  • IUGS-CGGB_7356_GTN_grid_cells_160x160km.zip (same as above but in a Google Earth kml file format). When unzipped the file name is: IUGS-CGGB_7356_GTN_grid_cells_160x160km.kml.

The above two files can be downloaded from the ‘Sampling/GTN 160x160 km’ web page.

(d) Randomly selected sampling points in each Global Terrestrial Network grid cell of 160x160 km files:

  • IUGS-CGGB_5-random-points_per_GTN_160x160km-grid-cell.xlsx (Microsoft™ Excel workbook file with 5 random points in each of the 7356 grid cells of 160x160 km totalling 36,780 random sampling points).
  • IUGS-CGGB_5-random-points_per_GTN_160x160km-grid-cell.zip (same as above but in a Google Earth kml file format). When unzipped the file name is: IUGS-CGGB_5-random-points_per_GTN_160x160km-grid-cell.kml.
  • IUGS-CGGB_8-random-points_per_GTN_160x160km-grid-cell.xlsx (Microsoft™ Excel workbook file with 8 random points in each of the 7356 grid cells of 160x160 km totalling 58,848 random sampling points).
  • IUGS-CGGB_8-random-points_per_GTN_160x160km-grid-cell.zip (same as above but in a Google Earth kml file format). When unzipped the file name is: IUGS-CGGB_8-random-points_per_GTN_160x160km-grid-cell.kml.
  • IUGS-CGGB_16-random-points_per_GTN_160x160km-grid-cell.xlsx (Microsoft™ Excel workbook file with 16 random points in each of the 7356 grid cells of 160x160 km totalling 117,696 random sampling points). It is noted that this sampling density is not recommended for the Global Geochemical Reference Network.
  • IUGS-CGGB_16-random-points_per_GTN_160x160km-grid-cell.zip (same as above but in a Google Earth kml file format). When unzipped the file name is: IUGS-CGGB_16-random-points_per_GTN_160x160km-grid-cell.kml.

The above six files can be downloaded from the ‘Sampling/Sampling Design’ web page.

(e) Global Marine Network grid cells of 160x160 km:

  • IUGS-CGGB_12477_GMN_160X160km_grid_cells.xlsx (Microsoft™ Excel workbook file with the 12,477 grid cells of the Global Marine Network each of 160x160 km).
  • IUGS-CGGB_12477_GMN_160x160km_grid_cells.zip (same as above but in a Google Earth kml file format. When unzipped the file name is: IUGS-CGGB_12477_GMN_160x160km_grid_cells.kml).

The above two files can be downloaded from the ‘Sampling/GMN 160 x 160 km’ web page.

The following files are necessary for the planning of the Global Marine Network random sampling campaign:

  • IUGS-CGGB_19833_GRN_160x160km_grid_cells.xlsx (File is the same as in (b)).
  • IUGS-CGGB_19833_GRN_160x160km_grid_cells.zip (File is the same as in (b)).
  • IUGS-CGGB_7356_GTN_160x160km_grid_cells.xlsx (File is the same as in (c)).
  • IUGS-CGGB_7356_GTN_grid_cells_160x160km.zip (File is the same as in (c)).
  • IUGS-CGGB_5-random-points_per_GTN_160x160km-grid-cell.xlsx (File is the same as in (d)).
  • IUGS-CGGB_5-random-points_per_GTN_160x160km-grid-cell.zip (File is the same as in (d)).
  • IUGS-CGGB_8-random-points_per_GTN_160x160km-grid-cell.xlsx (File is the same as in (d)).
  • IUGS-CGGB_8-random-points_per_GTN_160x160km-grid-cell.zip (File is the same as in (d)).

Notes

Citation: He, J. & Geng, X., 2022. R-scripts for Generation of 5, 8 and 16 Random Sampling Points Within Predefined Rectangles. IUGS Commission on Global Geochemical Baselines, Athens, Hellenic Republic, Special Publication, 3, 14 pp.; https://doi.org/10.5281/zenodo.7307202.

Files

He_Geng_2022_IUGS-CGGB_R-scripts_for_generation_of_5-8-16_random-sampling-points.pdf