<commit_before># Nytimes::Events

A Ruby wrapper for the NYTimes Event Listings API.

## Installation

Add this line to your application's Gemfile:

    gem 'nytimes-events'

And then execute:

    $ bundle

Or install it yourself as:

    $ gem install nytimes-events

## Usage

A simple usage example, as of right now:

    listing = Nytimes::Event::List.new(MY_API_KEY)
    listing.find('query' => 'food')

`search` takes a hash of parameters which directly correspond to the parameters found on the NYTimes' Event Listings API page. You must initialize any object with your API key which can be obtained from the NYTimes API website.

**IMPORTANT**
`nytimes-event` is based off of the linked-list data structure. That is, `Nytimes::Event::List` actually retrieves `batch_size` number of events, and you can retrieve the next `batch_size` events or the previous `batch_size` events.

`batch_size` by default is 20.

For example:

    listing = Nytimes::Event::List.new(MY_API_KEY)
    listing.batch_size = 10
    listing.find('query' => 'food')
    #=> next retrieves the next 10 events
    listing.next
    #=> previous retrieves the previous 10 events
    listing.prev

## Contributing

1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Added some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request
<commit_msg>fixed error in readme<commit_after># Nytimes::Events

A Ruby wrapper for the NYTimes Event Listings API.

## Installation

Add this line to your application's Gemfile:

    gem 'nytimes-events'

And then execute:

    $ bundle

Or install it yourself as:

    $ gem install nytimes-events

## Usage

A simple usage example, as of right now:

    listing = Nytimes::Event::List.new(MY_API_KEY)
    listing.find('query' => 'food')

`search` takes a hash of parameters which directly correspond to the parameters found on the NYTimes' Event Listings API page. You must initialize any object with your API key which can be obtained from the NYTimes API website.

**IMPORTANT**

`nytimes-event` is based off of the linked-list data structure. That is, `Nytimes::Event::List` actually retrieves `batch_size` number of events, and you can retrieve the next `batch_size` events or the previous `batch_size` events.

`batch_size` by default is 20.

For example:

    listing = Nytimes::Event::List.new(MY_API_KEY)
    listing.batch_size = 10
    listing.find('query' => 'food')
    #=> next retrieves the next 10 events
    listing.next
    #=> previous retrieves the previous 10 events
    listing.prev

## Contributing

1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Added some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request

{'fraction_non_alphanumeric': 0.08871812783793225, 'fraction_numerical': 0.009081383164512749, 'mean_word_length': 3.9636048526863084, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6730934', 'n_tokens_mistral': 866, 'n_tokens_neox': 833, 'n_words': 363}