czechrates
A package providing Czech FX and interest rates in R friendly format for analysis and visualization
Science Score: 44.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (14.4%) to scientific vocabulary
Repository
A package providing Czech FX and interest rates in R friendly format for analysis and visualization
Basic Info
Statistics
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
- Releases: 3
Metadata Files
README.md
czechrates
The package {czechrates} provides a convenient way to access the information stored on the ČNB website from the comfort of your R session. It does not store the rates (this would be against the terms of use, and the data would get stale rather soon).
As a consequence a working internet connection is required to fully use the package.
The ČNB mid FX rate is fixed against CZK by the Czech National Bank daily, and is the "official" CZK FX rate used for accounting, taxes and customs purposes. Even though ČNB does not actually deal at these rates the ČNB mid is one of the most relevant FX rates in the Czech republic – https://www.cnb.cz/en/faq/How-does-the-CNB-calculate-the-korunas-exchange-rate-against-other-currencies/
The PRague InterBank Offered Rates (PRIBOR - the CZK member of the broader IBOR family) are provided by the Czech National Bank as a courtesy of the Czech Financial Benchmark Facility s.r.o., the benchmark administrator of the PRIBOR benchmark. The rates can be accessed for internal purposes free of charge via internet pages of ČNB – https://www.cnb.cz/en/financial-markets/money-market/pribor/format-of-the-pribor-rate-on-the-cnb-website/
The two-week repo rate (a key policy rate) is formally announced by ČNB and also published on the ČNB internet – https://www.cnb.cz/en/faq/How-has-the-CNB-two-week-repo-rate-changed-over-time/
The package currently contains three functions:
-
czechrates::cnbfxrate()- ČNB mid CZK FX rate -
czechrates::pribor()- PRIBOR interest rate -
czechrates::repo2w()- two week REPO interest rate
All functions have date valid as the first argument, with yesterday (Sys.Date()-1) as default.
Both functions returning interest rate use convention of reporting percents as fractions, i.e. a interest rate of 1.5% per annum would be returned as 0.015, not as 1.5 as might be sometimes the case.
Installation
czechrates is on CRAN since June 2020; to install a stable version run:
r
install.packages("czechrates")
You are welcome to install the latest development version from GitHub by running:
r
remotes::install_github("jla-data/czechrates")
The master branch should be reasonably stable, but I do not recommend installing from development branches unless you know what you are doing. Things are bound to be somewhat rough around the edges there.
Example
A couple use cases:
``` r library(czechrates)
overnight PRIBOR for yesterday
pribor()
A tibble: 1 x 2
datevalid PRIBOR1D
overnight PRIBOR for April 1st, 2020
pribor(as.Date("2020-04-01"))
A tibble: 1 x 2
datevalid PRIBOR1D
weekly and monthly PRIBOR for April 1st, 2020
pribor(as.Date("2020-04-01"), c("1W", "1M"))
A tibble: 1 x 3
datevalid PRIBOR1W PRIBOR_1M
two-week REPO rate for yesterday
repo2w()
A tibble: 1 x 2
datevalid REPO2W
two-week repo rate for April 1st, 2020
repo2w(as.Date("2020-04-01"))
A tibble: 1 x 2
datevalid REPO2W
a complete table of CZK FX rates for yesterday
cnbfxrate()
A tibble: 33 x 4
datevalid currencycode amount rate
… with 23 more rows
EUR/CZK rate for April 1st, 2020
cnbfxrate(as.Date("2020-04-01"), "EUR")
A tibble: 1 x 4
datevalid currencycode amount rate
EUR/CZK rate for the week following April 1st, 2020
cnbfxrate(as.Date("2020-04-01") + 0:6, "EUR")
A tibble: 5 x 4
datevalid currencycode amount rate
A graphic example:
``` r library(czechrates) library(ggplot2)
chart_src <- pribor(seq(from = as.Date("1997-05-01"), to = as.Date("1997-06-30"), by = 1))
ggplot(data = chartsrc, aes(x = datevalid, y = PRIBOR1D)) + geomline(color = "red", size = 1.25) + geompoint(color = "red", size = 2) + scalexdate(datelabels = "%d.%m.%Y") + scaleycontinuous(labels = scales::percentformat()) + themebw() + labs(title = "A ghost of the times past, when the Asian Fever meant monetary contagion...", x = "Date", y = "Overnight PRIBOR (per annum)") + theme(plot.title = ggtext::element_markdown(size = 22)) ```
Owner
- Name: JLA Data
- Login: jla-data
- Kind: organization
- Website: www.jla-data.net
- Repositories: 2
- Profile: https://github.com/jla-data
Citation (CITATION.cff)
# -----------------------------------------------------------
# CITATION file created with {cffr} R package, v0.3.0
# See also: https://docs.ropensci.org/cffr/
# -----------------------------------------------------------
cff-version: 1.2.0
message: 'To cite package "czechrates" in publications use:'
type: software
license: MIT
title: 'czechrates: Czech Interest & Foreign Exchange Rates'
version: 0.2.3
abstract: Interface to interest and foreign exchange rates published by the Czech National Bank.
authors:
- family-names: Lacko
given-names: Jindra
email: jindra.lacko@gmail.com
orcid: https://orcid.org/0000-0002-0375-5156
repository: https://CRAN.R-project.org/package=czechrates
repository-code: https://github.com/jla-data/czechrates
url: https://github.com/jla-data/czechrates
contact:
- family-names: Lacko
given-names: Jindra
email: jindra.lacko@gmail.com
orcid: https://orcid.org/0000-0002-0375-5156
references:
- type: software
title: curl
abstract: 'curl: A Modern and Flexible Web Client for R'
notes: Imports
authors:
- family-names: Ooms
given-names: Jeroen
email: jeroen@berkeley.edu
orcid: https://orcid.org/0000-0002-4035-0289
year: '2022'
url: https://CRAN.R-project.org/package=curl
- type: software
title: httr
abstract: 'httr: Tools for Working with URLs and HTTP'
notes: Imports
authors:
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
year: '2022'
url: https://CRAN.R-project.org/package=httr
- type: software
title: readr
abstract: 'readr: Read Rectangular Text Data'
notes: Imports
authors:
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
- family-names: Hester
given-names: Jim
- family-names: Bryan
given-names: Jennifer
email: jenny@rstudio.com
orcid: https://orcid.org/0000-0002-6983-2759
year: '2022'
url: https://CRAN.R-project.org/package=readr
- type: software
title: dplyr
abstract: 'dplyr: A Grammar of Data Manipulation'
notes: Imports
authors:
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
orcid: https://orcid.org/0000-0003-4757-117X
- family-names: François
given-names: Romain
orcid: https://orcid.org/0000-0002-2444-4226
- family-names: Henry
given-names: Lionel
- family-names: Müller
given-names: Kirill
orcid: https://orcid.org/0000-0002-1416-3412
year: '2022'
url: https://CRAN.R-project.org/package=dplyr
version: '>= 1.0.0'
- type: software
title: magrittr
abstract: 'magrittr: A Forward-Pipe Operator for R'
notes: Imports
authors:
- family-names: Bache
given-names: Stefan Milton
email: stefan@stefanbache.dk
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
year: '2022'
url: https://CRAN.R-project.org/package=magrittr
- type: software
title: tibble
abstract: 'tibble: Simple Data Frames'
notes: Imports
authors:
- family-names: Müller
given-names: Kirill
email: krlmlr+r@mailbox.org
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
year: '2022'
url: https://CRAN.R-project.org/package=tibble
- type: software
title: tidyr
abstract: 'tidyr: Tidy Messy Data'
notes: Imports
authors:
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
- family-names: Girlich
given-names: Maximilian
year: '2022'
url: https://CRAN.R-project.org/package=tidyr
- type: software
title: testthat
abstract: 'testthat: Unit Testing for R'
notes: Suggests
authors:
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
year: '2022'
url: https://CRAN.R-project.org/package=testthat
- type: software
title: rmarkdown
abstract: 'rmarkdown: Dynamic Documents for R'
notes: Suggests
authors:
- family-names: Allaire
given-names: JJ
email: jj@rstudio.com
- family-names: Xie
given-names: Yihui
email: xie@yihui.name
orcid: https://orcid.org/0000-0003-0645-5666
- family-names: McPherson
given-names: Jonathan
email: jonathan@rstudio.com
- family-names: Luraschi
given-names: Javier
email: javier@rstudio.com
- family-names: Ushey
given-names: Kevin
email: kevin@rstudio.com
- family-names: Atkins
given-names: Aron
email: aron@rstudio.com
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
- family-names: Cheng
given-names: Joe
email: joe@rstudio.com
- family-names: Chang
given-names: Winston
email: winston@rstudio.com
- family-names: Iannone
given-names: Richard
email: rich@rstudio.com
orcid: https://orcid.org/0000-0003-3925-190X
year: '2022'
url: https://CRAN.R-project.org/package=rmarkdown
- type: software
title: ggplot2
abstract: 'ggplot2: Create Elegant Data Visualisations Using the Grammar of Graphics'
notes: Suggests
authors:
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
orcid: https://orcid.org/0000-0003-4757-117X
- family-names: Chang
given-names: Winston
orcid: https://orcid.org/0000-0002-1576-2126
- family-names: Henry
given-names: Lionel
- family-names: Pedersen
given-names: Thomas Lin
email: thomas.pedersen@rstudio.com
orcid: https://orcid.org/0000-0002-5147-4711
- family-names: Takahashi
given-names: Kohske
- family-names: Wilke
given-names: Claus
orcid: https://orcid.org/0000-0002-7470-9261
- family-names: Woo
given-names: Kara
orcid: https://orcid.org/0000-0002-5125-4188
- family-names: Yutani
given-names: Hiroaki
orcid: https://orcid.org/0000-0002-3385-7233
- family-names: Dunnington
given-names: Dewey
orcid: https://orcid.org/0000-0002-9415-4582
year: '2022'
url: https://CRAN.R-project.org/package=ggplot2
- type: software
title: scales
abstract: 'scales: Scale Functions for Visualization'
notes: Suggests
authors:
- family-names: Wickham
given-names: Hadley
email: hadley@rstudio.com
- family-names: Seidel
given-names: Dana
year: '2022'
url: https://CRAN.R-project.org/package=scales
- type: software
title: knitr
abstract: 'knitr: A General-Purpose Package for Dynamic Report Generation in R'
notes: Suggests
authors:
- family-names: Xie
given-names: Yihui
email: xie@yihui.name
orcid: https://orcid.org/0000-0003-0645-5666
year: '2022'
url: https://CRAN.R-project.org/package=knitr
- type: software
title: covr
abstract: 'covr: Test Coverage for Packages'
notes: Suggests
authors:
- family-names: Hester
given-names: Jim
email: james.f.hester@gmail.com
year: '2022'
url: https://CRAN.R-project.org/package=covr
GitHub Events
Total
- Watch event: 1
- Push event: 2
Last Year
- Watch event: 1
- Push event: 2
Committers
Last synced: about 3 years ago
All Time
- Total Commits: 30
- Total Committers: 1
- Avg Commits per committer: 30.0
- Development Distribution Score (DDS): 0.0
Top Committers
| Name | Commits | |
|---|---|---|
| Jindra Lacko | j****o@g****m | 30 |
Issues and Pull Requests
Last synced: 9 months ago
All Time
- Total issues: 1
- Total pull requests: 2
- Average time to close issues: 5 days
- Average time to close pull requests: less than a minute
- Total issue authors: 1
- Total pull request authors: 1
- Average comments per issue: 1.0
- Average comments per pull request: 0.0
- Merged pull requests: 2
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 0
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 0
- Pull request authors: 0
- Average comments per issue: 0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- jlacko (1)
Pull Request Authors
- jlacko (2)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- cran 579 last-month
- Total dependent packages: 0
- Total dependent repositories: 0
- Total versions: 6
- Total maintainers: 1
cran.r-project.org: czechrates
Czech Interest & Foreign Exchange Rates
- Homepage: https://github.com/jla-data/czechrates
- Documentation: http://cran.r-project.org/web/packages/czechrates/czechrates.pdf
- License: MIT + file LICENSE
-
Latest release: 0.2.5
published almost 2 years ago
Rankings
Maintainers (1)
Dependencies
- curl * imports
- dplyr >= 1.0.0 imports
- httr * imports
- magrittr * imports
- readr * imports
- tibble * imports
- tidyr * imports
- covr * suggests
- ggplot2 * suggests
- knitr * suggests
- rmarkdown * suggests
- scales * suggests
- testthat * suggests
- actions/checkout v4 composite
- r-lib/actions/check-r-package v2 composite
- r-lib/actions/setup-pandoc v2 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite
- actions/checkout v4 composite
- actions/upload-artifact v3 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite