Learn R Programming

iqfeed (version 0.2)

HIT: Retrieves historic interval bars within a given time interval for the specified symbol.

Description

Retrieves historic interval bars within a given time interval for the specified symbol.

Usage

HIT(symbol, interval = 3600, start, end, beginFilterTime = "", endFilterTime = "", tz="America/New_York")

Arguments

symbol
Any valid symbol.
interval
The interval period in seconds.
start
The starting date/time or just date.
end
The ending date/time or just date.
beginFilterTime
The beginning time of day (America/New_York) in the form "HHmmSS" (leave blank for all day).
endFilterTime
The ending time of day (America/New_York) in the form "HHmmSS" (leave blank for all day).
tz
The timezone code (defaults to "America/New_York").

Value

An xts time-series object with High, Low, Open, Close, and Volume bars over the requested interval.

Details

A basic attempt is made to interpret the date/time values. One may very explicitly specify the date/time parameters in the following format: "CCCC-MM-dd HH:mm:SS" and by specifying the tz parameter.

Examples

Run this code
require("iqfeed")
iqConf()
t0 <- "2010-01-18 15:25:00"
t1 <- "2010-01-22 10:00:00"
HIT("MSFT",interval=3600,start=t0,end=t1)

Run the code above in your browser using DataLab