getPrice: Zema API single call.

View source: R/zema.R

getPriceR Documentation

Zema API single call.

Description

Returns data from Zema API. See below for current feeds supported. You need your own credentials with Zema. In examples sourced locally.

Usage

getPrice(
  feed = "CME_NymexFutures_EOD",
  contract = "@CL21Z",
  from = "2020-09-01",
  iuser = "x@xyz.com",
  ipassword = "pass"
)

Arguments

feed

Zema Feed Table. character

contract

Zema key. character

from

From date yyyy-mm-dd. character

iuser

Zema user name as character - sourced locally in examples. character

ipassword

Zema user password as character - sourced locally in examples. character

Value

wide data frame. tibble

Current Feeds Supported

  • CME_CbotFuturesEOD and CME_CbotFuturesEOD_continuous

  • CME_NymexFutures_EOD, CME_NymexFuturesFinal_EOD andCME_NymexFutures_EOD_continuous

  • CME_NymexOptionsFinal_EOD and CME_NymexOptions_EOD

  • CME_CmeFutures_EOD and CME_CmeFutures_EOD_continuous

  • CME_Comex_FuturesSettlement_EOD and CME_Comex_FuturesSettlement_EOD_continuous

  • LME_AskBidPrices_Delayed

  • SHFE_FuturesSettlement_RT

  • ICE_EuroFutures and ICE_EuroFutures_continuous

  • ICE_NybotCoffeeSugarCocoaFutures and ICE_NybotCoffeeSugarCocoaFutures_continuous

  • CME_STLCPC_Futures

  • CFTC_CommitmentsOfTradersCombined. Requires multiple keys. Separate them by a space e.g. "N10 06765A NYME 01".

  • ERCOT_LmpsByResourceNodeAndElectricalBus.

  • PJM_Rt_Hourly_Lmp.

  • AESO_ForecastAndActualPoolPrice.

Author(s)

Philippe Cote

Examples

## Not run: 
getPrice(
  feed = "CME_NymexFuturesFinal_EOD", contract = "CL 2024 07",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_NymexFutures_EOD", contract = "@CL21Z",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_NymexFutures_EOD_continuous", contract = "CL_006_Month",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_NymexOptionsFinal_EOD", contract = "06 2024 P LO 8000",
  from = "2020-03-15", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_NymexOptions_EOD", contract = "@LO21ZP4000",
  from = "2020-03-15", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_CbotFuturesEOD", contract = "C0Z",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_CbotFuturesEOD_continuous", contract = "ZB_001_Month",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_CmeFutures_EOD_continuous", contract = "HE_006_Month",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_CmeFutures_EOD", contract = "LH0N",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "CME_CmeFutures_EOD_continuous", contract = "HE_006_Month",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "ICE_EuroFutures", contract = "BRN0Z",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "ICE_EuroFutures_continuous", contract = "BRN_001_Month",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "ICE_NybotCoffeeSugarCocoaFutures", contract = "SB21H",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "ICE_NybotCoffeeSugarCocoaFutures_continuous", contract = "SF_001_Month",
  from = "2019-08-26", iuser = username, ipassword = password
)
getPrice(
  feed = "AESO_ForecastAndActualPoolPrice", contract = "Forecast_Pool_Price",
  from = "2021-04-01", iuser = username, ipassword = password
)
getPrice(
  feed = "LME_MonthlyDelayed_Derived", contract = "AHD 2021-12-01 2021-12-31",
  from = "2021-04-01", iuser = username, ipassword = password
)

## End(Not run)


RTL documentation built on May 23, 2026, 5:07 p.m.