Description Usage Arguments Value Examples
View source: R/get_fin_statements.R
Uses the simfim api <https://simfin.com/> for downloading corporate financial datasets available at the website. In order to use the function, you'll need a valid api key from <https://simfin.com/data/access/api>. All data from the site is locally cached with package memoise, meaning it will never grab repeated data from the api.
1 2 3 4 5 6 7 8 | simfinR_get_fin_statements(
id_companies,
api_key,
type_statements = c("pl", "bs", "cf"),
periods = "FY",
years = 2018,
cache_folder = "simfin_cache"
)
|
id_companies |
Simfin Id of companies to get data (see |
api_key |
Your api key (get one at <https://simfin.com/data/access/api>) |
type_statements |
Types of financial statements ('pl' - profit loss, 'bs' - balance sheet, 'cf' - cashflow) |
periods |
Time periods to grab the data: 'FY' - fiscal year (only for 'pl' and 'cf', use 'Q4' for end of year 'bs'), 'Q1' - first quarter, 'Q2', 'Q3', 'Q4' |
years |
The years to grab data (vector or single value) |
cache_folder |
Directory for cache files |
A dataframe with financial statements
1 2 3 4 5 6 7 | ## Not run:
id_companies <- 59265
api_key <- 'YOURAPIHERE'
df_fin <- get_fin_statements(id_companies, api_key = api_key)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.