Learn R Programming

edgar (version 1.0.5)

getMasterIndex: Retrieves quarterly master index.

Description

getMasterIndex retrieves the quarterly master index from US SEC site.

Usage

getMasterIndex(year.array)

Arguments

year.array
year in integer or integer array containing years for which master index are to be downloaded.

Value

Function retrieves quarterly master index files from ftp://ftp.sec.gov/edgar/full-index site and returns download status data frame.

Details

getMasterIndex function takes filing year as an input parameter from user, download quarterly master index from ftp://ftp.sec.gov/edgar/full-index. It strips the headers, converts into data frame, and merges such quarterly data frames into yearly data frames and stored it in Rda format. Function creates new directory 'Master Index' into working directory to save these Rda Master Index. Please note, for all other functions in this package needs to locate the same working directory to access these Rda master index files.

Examples

Run this code
## Not run: 
# 
# report <- getMasterIndex(1995) 
# ## Download quarterly master index files for the year 1990 and stores into yearly  
# ## 1995master.Rda file. It returns download report in data frame format.
# 
# report <- getMasterIndex(c(1994, 1995, 2006)) 
# ## Download quarterly master index files for the years 1994, 1995, 2006 and stores into 
# ## different {year}master.Rda files. It returns download report in data frame format.
# ## End(Not run)

Run the code above in your browser using DataLab