Open paulfranz opened 8 years ago
Erik,
I have a question about the results of the re-indexing as well. I tweaked your working example code to report on just Jan 2014 - Mar 2016 in the US for the term "cfa". In the attached screenshot you can see my R plot with the Google Trends output below it. The red line is the SVI column from your summary data frame. Seeing as it is the same data, it tracks with the Google Trends chart. The black line is the Reindexed column from summary, and it seems very different. There are a few giant spikes (>250) in it that do not correlate with the SVI and the other way around. Is this the expected behavior?
gt_trends.r.zip
The spikes are expected behavior. It's a result of the daily series being a lot more volatile than weekly series. The main purpose of the reindexing is aligning the daily series with long term trends in the data that otherwise disappear. For a working example of the reindexing, check out this file: https://github.com/321k/Google-Trends/blob/master/Daily%20data%20example.R
The reindexing seems a little different to your other codes. Instead of calculating the adjustment factor by dividing daily through weekly, you did it the other way around. Furtermore I'm missing the part where you multiply the adjustment factor with the daily SVI. Could you explain it a little more?