If run this getSymbols function on Saturday it will return data for only completed weeks i.e. it will omit current week data and will only return data till 15th May 2021
d <- as.data.frame(
getSymbols(
paste("WIPRO" , ".NS", sep = ""),
from ="2000-01-01",
periodicity = "weekly",
return.class = 'zoo',
env = NULL
)
)
If I want this function to return data till today or whichever is latest, how do I modify this function?
If I add to = "2021-05-22"
parameter, it returns the record but it is filled with NA.