query.firms {FinNet}R Documentation

Function to extract information from multiple firm object (legal person)

Description

This function can be fed either: - a (possibly named) list of objects of class firm (see examples 1 and 2); or - multiple objects of class firm(see example 3)

Usage

query.firms(..., which, naming = TRUE)

Arguments

...

Object/s which to extract information from (see 'Details')

which

Information to extract, minimum unambiguous sub-string. Possible values (one or more): - name Name of the firm - id ID of the firm, usually the ticker (if provided or otherwise known) - legal_form Legal form of the firm - sector Sector in which the firm operates - revenues Yearly revenues - capitalisation Capitalisation - management Members of the board - ownership Owner(s) - shares Share owned by (each of) the owner(s) - currency Currency in which revenues and capitalisation are denominated

naming

Whether to name the result after the querie information (defaults to TRUE)

Value

Depends on the information queried. An object of class list (that, if length(which)>=2, contain multiple sub-lists) of the following:

name

A string representing the name of the firm

id

A string representing the ID of the firm (usually its ticker)

legal_form

A string representing the firm's legal form

sector

A string indicating the sector in which the firm operates (possibly a NACE rev. 2 code)

revenues

A numeric (double) quantifying yearly revenues

capitalisation

A numeric (double) quantifying capitalisation

management

A vector of strings representing the members of the board

ownership

A vector of strings representing the owner(s)

shares

A numeric (double) vector indicating the shares controlled by (each of) the owner(s)

currency

A string indicating the currency in which revenues and capitalisation are denominated

Author(s)

Telarico, Fabio Ashtar

See Also

query.firm query.firms.dataframe

Examples


# Query Apple's, GM's, and BTI's market cap and revenues
data('firms_US')
query.firms(firms_US, which = c('cap', 'rev'))

# Query GM's and BTI's management
data('firms_US')
query.firms(firms_US, which = 'man')

# Query Appple's and GM's revenues and currency
data('firms_US')
list2env(firms_US, envir = parent.frame())
query.firms(AAPL, GM, which = c('rev', 'curr'))



[Package FinNet version 0.1.2 Index]