View source: R/apsimx_filetype.R
apsimx_filetype | R Documentation |
Test whether an .apsimx file is XML or json
apsimx_filetype(file = "", src.dir = ".")
file |
file ending in .apsimx to be tested |
src.dir |
directory containing the .apsimx file to be tested; defaults to the current working directory |
‘xml’, ‘json’ or ‘unknown’
Minimal function which reads only the first line in a file and tries to guess whether it is an ‘xml’ or ‘json’ file type.
extd.dir <- system.file("extdata", package = "apsimx")
apsimx_filetype("Wheat.apsimx", src.dir = extd.dir)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.