@@ -182,10 +182,7 @@ stocks_hist <- function(symbols = c("VTI", "META"),
182
182
cache = TRUE ,
183
183
quiet = FALSE ,
184
184
... ) {
185
- cache_file <- c(
186
- as.character(Sys.Date()), " stocks_hist" ,
187
- symbols , sum(as.integer(as.Date(from )), as.integer(as.Date(to )))
188
- )
185
+ cache_file <- c(as.character(Sys.Date()), " stocks_hist" )
189
186
if (cache_exists(cache_file ) && cache ) {
190
187
results <- cache_read(cache_file , quiet = quiet )
191
188
return (results )
@@ -1087,7 +1084,6 @@ etf_sector <- function(etf = "VTI", quiet = FALSE, cache = TRUE) {
1087
1084
if (" daily_stocks" %in% attr(etf , " type" )) {
1088
1085
etf <- as.character(unique(etf $ Symbol [etf $ Date == max(etf $ Date )]))
1089
1086
}
1090
-
1091
1087
cache_file <- c(as.character(Sys.Date()), " etf_sector" , etf )
1092
1088
if (cache_exists(cache_file ) && cache ) {
1093
1089
results <- cache_read(cache_file , quiet = quiet )
@@ -1156,9 +1152,7 @@ etf_sector <- function(etf = "VTI", quiet = FALSE, cache = TRUE) {
1156
1152
# ' @rdname stocks_plots
1157
1153
splot_etf <- function (s , keep_all = FALSE , cache = TRUE , save = FALSE ) {
1158
1154
check_attr(s , check = " daily_stocks" )
1159
-
1160
1155
if (! " Date" %in% colnames(s )) s $ Date <- Sys.Date()
1161
-
1162
1156
cache_file <- c(as.character(Sys.Date()), " splot_etf" , s )
1163
1157
if (cache_exists(cache_file ) && cache ) {
1164
1158
etfs <- cache_read(cache_file , quiet = quiet )
0 commit comments