get_companies | R Documentation |
get_companies
reads in the contents of a text file
created from the pdf of company names and tickers given by
the Russell 3000 Index.
get_companies(filepath = system.file("extdata/companies.txt", package = "qmj"))
filepath |
Specifies the filepath of the text file containing the company names and tickers of interest. May be either absolute or relative to working directory. |
The user must copy and paste the contents of the Russell 3000 Index into a text file for this function to process the data correctly. Simply select all of the component list and paste the contents into an empty document with the .txt extension. The list may be found here.
If you wish to use your own text file of companies for get_companies to process, create a text file containing each company on a separate line. Every word and ticker must be capitalized, and the ticker must be the last word, separated by a space, on each line.
get_companies
by default uses a text file created from
the Russell 3000 Index in the package.
data.frame of companies info
get_companies()
: function splits by space and grabs everything before
the last word as the name and has the last word as the ticker.
Which chunk it returns is determined by the is_name variable.
get_companies()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.