Converts the tabular output of export_ebi_pheno() into JSON
files formatted for submission to EBI as BioSample data
(https://www.ebi.ac.uk/amr/amr_submission_guide/). Each row of the input
dataset is converted into JSON records and printed to file.
Arguments
- ebi_antibiogram_table
A data frame in the format output by
export_ebi_pheno().- submission_account
Character string specifying the Webin submission account identifier (e.g.
"Webin-###").- output_dir
Character string specifying the directory where JSON files should be written.
- domain
(Optional) Character string specifying the domain used in the submission metadata (default
"self.ExampleDomain").
Details
The function iterates over each biosample in ebi_antibiogram_table and
constructs
a nested JSON object describing the antimicrobial susceptibility
testing result. Each record contains antibiotic metadata, AST
standards, measurement values, and resistance phenotype information.
JSON formatting is performed using jsonlite::toJSON() with
pretty = TRUE and auto_unbox = TRUE .
