XBRL {XBRL} | R Documentation |
"Mutable state" function that exposes "methods" that analyze an XBRL instance an its associated DTS.
Description
XBRL
is a "mutable state" function that offers a object-oriented
programming-like interface, by exposing "methods" that perform accions
on XBRL files. It keeps a list of data frames that are populated by
the "methods" by calls to the low-level functions (see
xbrlParse
).
The approach used is derived from an example included in *10.7 Scope*
of *An Introduction to R*. The employed terminology may be inaccurate,
hence the quotations. XBRL
"methods" are called by
xbrlDoAll
. See examples of use below.
Usage
XBRL()
Arguments
no arguments
Value
a list of "methods"
Author(s)
Roberto Bertolusso and Marek Kimmel
See Also
Examples
## Not run:
## Setting stringsAsFactors = FALSE is highly recommended
## to avoid data frames to create factors from character vectors.
options(stringsAsFactors = FALSE)
## XBRL instance file to be analyzed, accessed
## directly from SEC website:
inst <- "https://www.sec.gov/Archives/edgar/data/21344/000002134413000050/ko-20130927.xml"
xbrl <- XBRL()
xbrl$setCacheDir("XBRLcache")
xbrl$openInstance(inst)
## Perform a discovery of the taxonomy:
xbrl$processSchema(xbrl$getSchemaName())
## Process instance file:
xbrl$processContexts()
xbrl$processUnits()
xbrl$processFacts()
xbrl$processFootnotes()
xbrl$closeInstance()
xbrl.vars <- xbrl$getResults()
## End(Not run)
[Package XBRL version 0.99.19.1 Index]