[R-SIG-Finance] get data in quantmod

Rowe, Brian Lee Yung (Portfolio Analytics) B_Rowe at ml.com
Wed Feb 25 16:30:05 CET 2009

1: From the code for getSymbols.yahoo this appears to be hardcoded. The
parameter to set the series frequency on yahoo is 'g':

=m&q=q&y=0&z=FXP&x=.csv - returns monthly

=d&q=q&y=0&z=FXP&x=.csv - returns daily

Here is the code in getSymbols.yahoo:
        download.file(paste(yahoo.URL, "s=", Symbols.name, "&a=",
            from.m, "&b=", sprintf("%.2d", from.d), "&c=", from.y,
            "&d=", to.m, "&e=", sprintf("%.2d", to.d), "&f=",
            to.y, "&g=d&q=q&y=0", "&z=", Symbols.name, "&x=.csv",
            sep = ""), destfile = tmp, quiet = !verbose)

Note the "&g=d" is hardcoded (at least in my versions 0.3-6, 0.3-7)

2: This has been asked before (see attached).


-----Original Message-----
From: r-sig-finance-bounces at stat.math.ethz.ch
[mailto:r-sig-finance-bounces at stat.math.ethz.ch] On Behalf Of BearXu
Sent: Wednesday, February 25, 2009 10:11 AM
To: r-sig-finance at stat.math.ethz.ch
Subject: [R-SIG-Finance] get data in quantmod

I have two questions about how to get data in quantmod
1)Yahoo Finance provide us with data in daily, weekly, monthly. When we
using getSymbols can we choose the time spectrum?

2)I want to download some Chinese Stock Data, So I use this command:
getSymbols("600089.SS"), but when I want to use command
it's wrong. Maybe the problem is the name of the object "600089.SS". So
I give another name to the object from the getSymbols?


	[[alternative HTML version deleted]]

R-SIG-Finance at stat.math.ethz.ch mailing list
-- Subscriber-posting only.
-- If you want to post, subscribe first.

This message w/attachments (message) may be privileged, confidential or proprietary, and if you are not an intended recipient, please notify the sender, do not use or share it and delete it. Unless specifically indicated, this message is not an offer to sell or a solicitation of any investment products or other financial product or service, an official confirmation of any transaction, or an official statement of Merrill Lynch. Subject to applicable law, Merrill Lynch may monitor, review and retain e-communications (EC) traveling through its networks/systems. The laws of the country of each sender/recipient may impact the handling of EC, and EC may be archived, supervised and produced in countries other than the country in which you are located. This message cannot be guaranteed to be secure or error-free. References to "Merrill Lynch" are references to any company in the Merrill Lynch & Co., Inc. group of companies, which are wholly-owned by Bank of America Corporation. Securities and Insurance Products: * Are Not FDIC Insured * Are Not Bank Guaranteed * May Lose Value * Are Not a Bank Deposit * Are Not a Condition to Any Banking Service or Activity * Are Not Insured by Any Federal Government Agency. Attachments that are part of this E-communication may have additional important disclosures and disclaimers, which you should read. This message is subject to terms available at the following link: http://www.ml.com/e-communications_terms/. By messaging with Merrill Lynch you consent to the foregoing.

-------------- next part --------------
An embedded message was scrubbed...
From: "Brian Lee Yung Rowe" <brian at muxspace.com>
Subject: Re: [R-SIG-Finance] Newbie question on getSymbols() in quantmod
Date: Tue, 30 Dec 2008 22:31:39 -0500
Size: 4340
URL: <https://stat.ethz.ch/pipermail/r-sig-finance/attachments/20090225/6a13787d/attachment.mht>
-------------- next part --------------
An embedded message was scrubbed...
From: "Jeff Ryan" <jeff.a.ryan at gmail.com>
Subject: Re: [R-SIG-Finance] Newbie question on getSymbols() in quantmod
Date: Wed, 31 Dec 2008 00:04:21 -0500
Size: 5616
URL: <https://stat.ethz.ch/pipermail/r-sig-finance/attachments/20090225/6a13787d/attachment-0001.mht>

More information about the R-SIG-Finance mailing list