[R-SIG-Finance] About yahooImport to display output on R console

Jeff Ryan jeff.a.ryan at gmail.com
Wed Dec 15 06:08:55 CET 2010


Hi Stephen,

Try:

library(quantmod)

getSymbols("IBM")
getSymbols("IBM", src="google")

Both will autoload into your global environment, though this is settable.

HTH
Jeff

On Tue, Dec 14, 2010 at 11:01 PM, Stephen Liu <satimis at yahoo.com> wrote:
> Hi all,
>
> OS - Ubuntu 1010 desktop 64bit w/o gui
>
>> require('fImport')
> Loading required package: fImport
> Loading required package: timeDate
> Loading required package: timeSeries
>
>> yahooImport("IBM")
> trying URL
> 'http://chart.yahoo.com/table.csv?s=IBM&a=&b=&c=&d=11&e=15&f=2010&g=d&x=.csv'
> Content type 'text/csv' length unknown
> opened URL
> .......... .......... .......... .......... ..........
> .......... .......... .......... .......... ..........
> .......... .......
> downloaded 617 Kb
>
> It won't display the data on R console
>
>
> I must run;
>> yahooImport("IBM", file="IBM.csv", save=T)
> to save the file.
>
>> list.files(getwd(), full.name=T)
>  [1] "/home/satimisub1010dk02/Desktop"
>  [2] "/home/satimisub1010dk02/Documents"
>  [3] "/home/satimisub1010dk02/Downloads"
>  [4] "/home/satimisub1010dk02/examples.desktop"
>  [5] "/home/satimisub1010dk02/IBM.csv"
> .....
> ....
>
>
> I looked at ?yahooImport and couldn't resolve making it display the stock data
> on R console.  Any advice?
>
>
> Besides is there a tool to download stock data from Google finance instead of
> using their download tool?
>
> TIA
>
> B.R.
> Stephen L
>
>
>
>        [[alternative HTML version deleted]]
>
> _______________________________________________
> R-SIG-Finance at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-finance
> -- Subscriber-posting only. If you want to post, subscribe first.
> -- Also note that this is not the r-help list where general R questions should go.
>



-- 
Jeffrey Ryan
jeffrey.ryan at lemnica.com

www.lemnica.com



More information about the R-SIG-Finance mailing list