View source: R/liquidity_cryptowat.R
calcBestOrdersAndTradesBased | R Documentation |
This function calculates liquidity measures based on best orders and last trade
calcBestOrdersAndTradesBased(market, pair, sourceDirectory, destDirectory)
market |
is the required exchange |
pair |
is the required exchange rate pair |
sourceDirectory |
is the directory path where the matched.csv file is located |
destDirectory |
is the directory path where the matched_liquidity_measures.csv file will be saved |
This function calculates liquidity measures based on best orders and last trade
df is a dataframe with liquidity measures based on best orders and last trades
## Not run:
data_file<-system.file("extdata", package = "bitcoinFinance")
prepareTradesFromDirectory("coinbase","btcusd",data_file,data_file)
prepareOrders("coinbase","btcusd",data_file,data_file)
prepareBestOrders ("coinbase","btcusd",data_file )
lastPriceToBestOrders ("coinbase","btcusd",data_file )
trades_liquidity<-calcTradeBased("coinbase","btcusd",data_file, data_file )
bestorders_liquidity<-calcBestOrderBased("coinbase","btcusd",data_file, data_file )
bestorders_liquidity_trades<-calcBestOrdersAndTradesBased("coinbase","btcusd",data_file, data_file )
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.