rentals: List Available Rentals

Description Usage Arguments Examples

View source: R/rentals.R

Description

Get a list of housing available on craiglist using your own specifications

Usage

1
2
3
4
5
6
rentals(location = "seattle", area = "all", base_url = NULL,
  detailed = FALSE, output = NULL, max_results = 2500, query = NULL,
  postal = NULL, search_distance = NULL, bedrooms = NULL,
  bathrooms = NULL, min_price = NULL, max_price = NULL, min_sqft = NULL,
  max_sqft = NULL, has_pic = FALSE, posted_today = FALSE,
  pets_cat = FALSE, pets_dog = FALSE)

Arguments

location

Character vector containing the region to look in. Matches the craigslist subdomain for your region. Default is "seattle".

area

Character vector containing the specific area to look in. Matches the craigslist three-letter code for yoru area. Default is "all".

base_url

Optional character vector containing the craigslist base url. This overwrites the location and area parameters if supplied.

detailed

Logical indicating whether to return detailed search results, attempting to scrape extra information from listing pages. Detailed results take longer to acquire. Default is FALSE.

output

Optional character vector naming a CSV file to save to. Default is no output.

max_results

Numeric specifying the maximum number of results to display. Results are obtained 100 at a time, so the value will be rounded to the nearest 100. Defaults at the craigslist maximum of 2500.

query

Optional character vector containing a search term to supply to craiglist.

postal

Optional numeric postal code specifying an area to search in.

search_distance

Optional numeric supplying a distance from the specified postal code.

bedrooms

Optional character vector specifying the desired number of bedrooms.

bathrooms

Optional character vector specifying the desired number of bathrooms.

min_price

Optional numeric containing minimum price.

max_price

Optional numeric containing maximum price.

min_sqft

Optional numeric containing minimum square footage.

max_sqft

Optional numeric containing maximum square footage.

has_pic

Logical specifying whether listing must contain a photo. Default is FALSE.

posted_today

Logical specifying whether listing must have been posted today. Default is FALSE.

pets_cat

Logical specifying whether apartment must allow cats. Default is FALSE.

pets_dog

Logical specifying whether apartment must allow dogs. Default is FALSE.

Examples

1
rentals(location = "seattle", area = "see", bedrooms = 5, query = "downtown")

adletaw/craigr documentation built on Feb. 21, 2020, 10:14 p.m.