Creates a list of data options of class tidyfinance_data_options used for
TidyFinance-related functions. These options map the specific data variables
to the TidyFinance naming conventions, allowing functions to flexibly work
with different datasets by specifying the relevant column names. Additional
options can be passed through ....
Usage
data_options(
id = "permno",
date = "date",
exchange = "exchange",
mktcap_lag = "mktcap_lag",
ret_excess = "ret_excess",
portfolio = "portfolio",
siccd = "siccd",
price = "prc_adj",
listing_age = "listing_age",
be = "be",
earnings = "ib",
...
)Arguments
- id
A character string representing the entity variable (defaults to
"permno").- date
A character string representing the date variable (defaults to
"date").- exchange
A character string representing the exchange variable (defaults to
"exchange").- mktcap_lag
A character string representing the market capitalization lag variable (defaults to
"mktcap_lag").- ret_excess
A character string representing the excess return variable (defaults to
"ret_excess").- portfolio
A character string representing the portfolio variable (defaults to
"portfolio").- siccd
A character string representing the Standard Industrial Classification code variable (defaults to
"siccd").- price
A character string representing the (adjusted) price variable (defaults to
"prc_adj").- listing_age
A character string representing the listing age variable (defaults to
"listing_age").- be
A character string representing the book equity variable (defaults to
"be").- earnings
A character string representing the earnings variable (defaults to
"ib", the Compustat income before extraordinary items column).- ...
Additional arguments to be included in the data options list.
Examples
data_options(
id = "permno",
date = "date",
exchange = "exchange"
)
#> $id
#> [1] "permno"
#>
#> $date
#> [1] "date"
#>
#> $exchange
#> [1] "exchange"
#>
#> $mktcap_lag
#> [1] "mktcap_lag"
#>
#> $ret_excess
#> [1] "ret_excess"
#>
#> $portfolio
#> [1] "portfolio"
#>
#> $siccd
#> [1] "siccd"
#>
#> $price
#> [1] "prc_adj"
#>
#> $listing_age
#> [1] "listing_age"
#>
#> $be
#> [1] "be"
#>
#> $earnings
#> [1] "ib"
#>
#> attr(,"class")
#> [1] "tidyfinance_data_options"