boxoffice (version 0.1.0)

boxoffice: Download Information on Box Office Results for Movies

Description

Download Information on Box Office Results for Movies

Usage

boxoffice(start_date, end_date = NULL, number_of_results = NULL, source = "mojo", verbose = FALSE)

Arguments

start_date
Enter the first date in the range, or the specific date you want, or the list of dates you want. Dates must be in year/month/date format.
end_date
If you use a date range, this will be your end date in the range (inclusive). Dates must be in year/month/date format
number_of_results
How many results for each day (e.g. an input of 10 will return the top 10 movies that day)
source
Whether you want to get data from boxofficemojo.com or the-numbers.com.
verbose
Provides progress updates (which dates have been scraped and the percent total done)

Value

Data frame returning info on the name of the movie, its daily gross, gross-to-date, and gross-per-theater for each date inputted.

Examples

Run this code
# This will give you all movies from October 10th
# 2012 from the-numbers.com
boxoffice("12-10-10", source = "numbers")

# This will do the same as above but from
# boxofficemojo.com. Each site has
# slightly differing results. Note that
# boxofficemojo is default
# and does not need to be manually inputted
## Not run: boxoffice("12-10-10")

# Date range from October 10th - October 11th 2012
## Not run: boxoffice("12-10-10", "12-10-11")

# Same as above, only grab top 10 movies
## Not run: boxoffice("12-10-10", "12-10-11", number_of_results = 10)

# Same as above, with the-numbers.com as source
## Not run: boxoffice("12-10-10", "12-10-11",
# number_of_results = 10, source = "numbers")## End(Not run)

# Multiple dates
## Not run: boxoffice(c("12-10-10", "13-4-15"))

# Multiple dates with the-numbers as source
## Not run: boxoffice(c("12-10-10", "13-4-15"), source = "numbers")

Run the code above in your browser using DataCamp Workspace