Closed pcias closed 1 year ago
Thanks for reporting. This is a duplicate of https://github.com/stevecondylios/priceR/issues/49 and has been fixed in priceR version 1.0.1 on GitHub. It can be installed like so
devtools::install_github("stevecondylios/priceR")
I have submitted this package version to CRAN and will hopefully be live on CRAN soon.
this example from the package:
library(dplyr)
sales_transactions <- tibble( local_price = c(100, 80, 9200, 90), local_currency = c("USD", "EUR", "JPY", "USD"), final_currency = c("EUR", "USD", "USD", "JPY"), date_transaction = lubridate::ymd(c(20200601, 20200609, 20200614, 20200623)) )
Some made-up sales transactions of different values and currencies
sales_transactions %>% mutate( converted_price = convert_currencies( price_start = local_price, from = local_currency, to = final_currency, date = date_transaction ) )
returns: