merge_files {geojsonR} | R Documentation |
merge json files (or any kind of text files) from a directory
Description
merge json files (or any kind of text files) from a directory
Usage
merge_files(
INPUT_FOLDER,
OUTPUT_FILE,
CONCAT_DELIMITER = "\n",
verbose = FALSE
)
Arguments
INPUT_FOLDER |
a character string specifying a path to the input folder |
OUTPUT_FILE |
a character string specifying a path to the output file |
CONCAT_DELIMITER |
a character string specifying the delimiter to use when merging the files |
verbose |
either TRUE or FALSE. If TRUE then information will be printed in the console. |
Details
This function is meant for json files but it can be applied to any kind of text files. It takes an input folder (INPUT_FOLDER) and an output file (OUTPUT_FILE) and merges all files from the INPUT_FOLDER to a single OUTPUT_FILE using the concatenation delimiter (CONCAT_DELIMITER).
Examples
## Not run:
library(geojsonR)
merge_files(INPUT_FOLDER = "/my_folder/", OUTPUT_FILE = "output_file.json")
## End(Not run)
[Package geojsonR version 1.1.1 Index]