query.firms.dataframe {FinNet}R Documentation

Function to extract information from multiple firm object (legal person) as a data frame

Description

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

Usage

query.firms.dataframe(..., which, naming = TRUE, transposing = 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 queried information (defaults to TRUE)

transposing

If TRUE (default) each row will correspond to a firm and each column to a variable.

Details

It is not recommended to use this function with management, ownership, or shares unless transposing == FALSE.

Value

A data frame in structured as follows (or vice versa if transposing == TRUE):

a row

for each queried information; and

a column

for each number of firm

.

Author(s)

Telarico, Fabio Ashtar

See Also

query.firm query.firms

Examples


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

# Query GM's and BTI's market cap and revenues
data('firms_US')
list2env(firms_US, envir = parent.frame())
query.firms.dataframe(GM, BTI, which = c('cap', 'rev'))



[Package FinNet version 0.1.2 Index]