quantmod (version 0.4-10)

getSymbols.google: Download OHLC Data From Google Finance

Description

Downloads Symbols to specified env from ‘finance.google.com’. This method is not to be called directly, instead a call to getSymbols(Symbols,src='google') will in turn call this method. It is documented for the sole purpose of highlighting the arguments accepted, and to serve as a guide to creating additional getSymbols ‘methods’.

Usage

getSymbols.google(Symbols,
                 env,
                 return.class = 'xts',
                 from = "2007-01-01",
                 to = Sys.Date(),
                 ...)

Arguments

Symbols

a character vector specifying the names of each symbol to be loaded

env

where to create objects. (.GlobalEnv)

return.class

class of returned object

from

Retrieve no earlier than this date

to

Retrieve though this date

additional parameters

Value

A call to getSymbols.google will load into the specified environment one object for each Symbol specified, with class defined by return.class. Presently this may be ts, zoo, xts, or timeSeries.

Details

Meant to be called internally by getSymbols (see also).

One of a few currently defined methods for loading data for use with quantmod. Essentially a simple wrapper to the underlying Google Finance site for historical data.

A word of warning. Google is the home of BETA, and historic data is no exception. There is a BUG in practically all series that include the dates Dec 29,30, and 31 of 2003. The data will show the wrong date and corresponding prices. This essentially makes it useless, but if they ever apply a fix the data is nice(r) than Yahoo, in so much as it is all split adjusted and there is forty years worth to be had. As long as you skip the holiday week of 2003. : )

References

Google Finance: http://finance.google.com

See Also

getSymbols, setSymbolLookup

Examples

Run this code
# NOT RUN {
# All 3 getSymbols calls return the same
# MSFT to the global environment
# The last example is what NOT to do!

## Method #1
getSymbols('MSFT',src='google')


## Method #2
setDefaults(getSymbols,src='google')
  # OR
setSymbolLookup(MSFT='google')

getSymbols('MSFT')

#########################################
##  NOT RECOMMENDED!!!
#########################################
## Method #3
getSymbols.google('MSFT',verbose=TRUE,env=globalenv())
# }

Run the code above in your browser using DataCamp Workspace