Fetching option data in R

Discussion in 'Data Sets and Feeds' started by Bben1006, Apr 3, 2010.

  1. Using the fImport library in R, I can fetch any ticker data from yahoo--for example: :

    xx<-yahooSeries(tiker, nDaysBack=350)

    but is there a way to fetch in R the for option collage of that ticker –even only for the current day qoute?

    If not, I will appreciate any suggestion on how to do this in R

  2. I assume you mean options chain? If so, unfortunately, yahoo does not provide the data directly in .csv format as it does with equities.

    One approach you can try that works is to go to

    download the ticker chain you want and then read the downloaded file into R via:

    This will read the chain into a data frame.
    You could scrape directly from the page, as (not as obfuscated as yahoo), the data is embedded in the html code, although it would be a royal pain.

    If you or anyone else finds a simple way to scrape it directly from a site, let me know!
  3. Thanks--
    I thin this will work