
Add Geolocator DP resources from a GeoPressureTemplate
Source:R/add_gldp_geopressuretemplate.R
add_gldp_geopressuretemplate.Rd
This function adds all possible resources to a GeolocatoR Data Package by reading data from a GeoPressureTemplate directories and files.
The function performs the following steps:
If
"interim"
infrom
, reads all interim ".RData" files, extract all variables and add corresponding resources to the package (measurements
,twilights
,staps
,paths
,edges
, andpressurepaths
). Generated automatically temporarytags
andobservations
tables from theparam
in the interim file.If
"raw-data"
infrom
, search for all tag_id indata/raw-data/
which were not included frominterim
. It will use at leasttag_create
and if possibletag_label
andtag_set_map
usingconfig.yml
.It will also generate or updatetags
andobservations
table from the the tag data.Reads the
tags.csv
(ortags.xlsx
if present) andobservations.csv
(orobservations.xlsx
if present) from the./data
directory if they exist and overwrite the previously generatedtags
andobservations
.
You can exclude interim file or raw-tag folder to be included in the package by starting the
file name with an "_"
.
It is possible to do a mix of some tag
read from "interim"
and other from "raw-data"
simultaneously.
You can find more information on the use of this function in the GeoPressureManual
Usage
add_gldp_geopressuretemplate(
pkg,
directory = ".",
from = c("raw-tag", "interim")
)