Thursday, July 17, 2014

Indexing daily Google Trends data using R

If you want to us daily Google Trends data for statistical analysis, you will most likely want to go beyond the 90 day limitation Google has set on the data. How would you do that? You might start by simply piecing together the data Google gives you.

I've downloaded the csv file each month between 2004-2013 for the querry "FTSE 100". This is what you get:
Not very pretty is it. If you compare it to the weekly Google Trends data for the same querry, you can see that they look quite different from each other.


 Ideally, we would like to get the increased accuracy of daily data, while keeping the indexing intact. The way I've solved this problem is by reindexing the data back to the weekly index. Each weekly observation provides a reindexing point. Then you get this:

Looks a lot better, right? Here's two more examples, BP and Experian.


No comments:

Entertaining Blogs - BlogCatalog Blog Directory
Bloggtoppen.se