Though the timestamp indexes don't invariably correspond in a convenient 1:1 manner (I almost suspect this was intentional on Google's part) there is a pattern. POSIX time stamps, very helpfully decoded by appear in the timestamp column at 3-week intervals. Using this link: Īnd changing the stock ticker at the end will give you the past 50 days of trading days on 1/2-hourly increment. This was problematic because I need all the stock series to lie neatly on to of each other for the analysis I'm doing.įortunately, there is still a general structure to the data. For a high-volume stock like APPL that's no problem, but for low-volume small caps it means that your series will be missing much if not the majority of the data. Even worse, stocks that only trade at low volumes only have entries where a transaction is recorded. The problem is that while Google provides the past 50 training days of data for all exchange-traded stocks, the time stamps within the days are not standardized: an index of '1,' for example could either refer to the first of second time increment on the first trading day in the data set. So downloading and standardizing the data ended up being more much of a bear than I figured it would-about 150 lines of code. Remaining values from first column seem to be some sort of offset from first row value. But quick check on google finance reveals, those were indeed price levels on 10th Jan 2013. Note that I didn't know which day data you had requested. So if we offset our timestamps by this amount we should get : as.POSIXct(1357828200-300*60, origin = '', tz='EST') Note the first value of first column a1357828200, my intuition was that this has something to do with POSIXct. Please note this is my interpretation and I could be wrong. I will try to answer timestamp question first.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |