dimazest/google-ngram-downloader — pull request #5 by neocortex (2014-09-23 09:58:41+00:00)
Title: Added 'indices' keyword.

Hi @dimazest,

thanks for making this available.

While using this, I missed the option to iterate over only specific indices, e.g. if I only want to download 1-grams that start with an 'a'. As it is now, the the iteration goes through all available indices (which is exhausting if, for instance, I don't care about n-grams starting with a digit).

I added a `indices` keyword to `readline_google_store`. Default value is `None`, so not specifying it, everything works as it has, and iteration is over all possible indices.

You can pass it a list of indices like this:

```
fname, url, records = next(readline_google_store(ngram_len=1, indices=['z'']))
fname, url, records = next(readline_google_store(ngram_len=1, indices=['a', 'b']))
fname, url, records = next(readline_google_store(ngram_len=3, indices=['ab', 'be', 'rt']))
```