Learn R Programming

rbitcoinchartsapi (version 1.0.4)

GetWeightedPrices: This function returns the weighted prices.

Description

Bitcoincharts offers weighted prices for several currencies that can be used, for example, to price goods and services in Bitcoins -- this will yield much lower fluctuations than using a single market's latest price.

Usage

GetWeightedPrices()

Arguments

Value

Weighted prices are calculated for the last 24 hours, 7 days and 30 days; if there are no trades during an interval, such as no trade within 24 hours, then no value will be returned.

Examples

Run this code
tryCatch(
     weightedPrices <- GetWeightedPrices (),
     error =
         function (e) {
             print (
                 paste (
                     "An exception was thrown -- details follow: ",
                     e,
                     sep=""
                 )
             )
         }
     )

Run the code above in your browser using DataLab