quantmod
quantmod copied to clipboard
Modify getSymbols.SQLite
- Comment out setting of column names because Data are not just "OHLC".
- Order by first element of "db.fields".
I think you're going to need to describe your rationale for the change to order_by. The data pulled ultimately needs to be converted to xts, so some standardization is required on the order_by data.
As for column names, I agree with the spirit that not all data is OHLCVA. I would suggest naming the columns for the columns in the SQLite data to start. Then, we could test for OHLC, BBO, etc using other functional already in quantmod for that purpose. Simply eliminating column name setting entirely doesn't seem like a general solution.
- Currently conflicts with issue #51, and will not be merged until it is consistent with the solutions proposed in that issue: i.e. simply not setting colnames isn't going to be merged, because it conflicts with intended functionality. Also,
getSymbols.MySQL
should be fixed too. - This bug is described in #21, and also needs to be fixed in
getSymbols.MySQL
(maybe others).
-
Data can be ordered by a new argument: "Date_col" that is the column name of date in database.
-
Pseudo code:
if there is col.names, colnames of output = col.names. else there is only df.fields, colnames of output = df.fields without the column name of date.