I am trying to substitute some excels that we were using to retrieve some data from bloomberg, with a script in R that can automate some tasks.
Usually with rblpapi I can use the same commands that works for Excel in R, but I have founded one that does not. The following command in Excel:
=BDP("ABG SM Equity" ; "ARD_NET_INC" ; "FUND_PER=C")
returns the number I need, but if I try this one in R:
bdp( "ABG SM Equity" , "ARD_NET_INC", "FUND_PER=C")
it sends the error message:
Error in bdp_Impl(con, securities, fields, options, overrides, verbose, : Request options must be named.
I have tried options= c("FUND_PER","C")
and many possible combinations but it returns error messages like:
Attempt to access unknown sub-element 'FUND_PER' on element 'ReferenceDataRequest'
How do I specify the option properly or just get that data from the request?
I am using R 3.4.0 on windows.
Thx in advance.
The next code did the trick:
I just needed to use overrides instead of options.