
Add Geolocator DP resources from a GeoPressureTemplate
Source:R/add_gldp_geopressuretemplate.R
add_gldp_geopressuretemplate.RdThis 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 temporarytagsandobservationstables from theparamin 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_createand if possibletag_labelandtag_set_mapusingconfig.yml.It will also generate or updatetagsandobservationstable from the the tag data.Reads the
tags.csv(ortags.xlsxif present) andobservations.csv(orobservations.xlsxif present) from the./datadirectory if they exist and overwrite the previously generatedtagsandobservations.
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")
)