Total return data from Bloomberg

73 次查看(过去 30 天)
Hi
I am trying to pull total return figure for Microsoft from 20080901 to 20090901. I used the below formula but this does not seem to work.This shows an error message. a4=getdata(c,'MSFT US Equity','CUST_TRR_RETURN_HOLDING_PER','CUST_TRR_Start_DT','20080101','CUST_TRR_END_DT','20090901')
I then tried
a4=getdata(c,'MSFT US Equity','CUST_TRR_RETURN_HOLDING_PER','CUST_TRR_END_DT','20090901'). however, the result seems to be the total return figure for today (20180828), rattan than the historical figure I am trying to get.
I then tried a4=history(c,'MSFT US Equity','CUST_TRR_RETURN_HOLDING_PER','CUST_TRR_Start_DT','20080901','CUST_TRR_END_DT','20090901'). this also caused an error message.
Does anyone know how to pull historical total return figures for a stock from Bloomberg? Many thanks

采纳的回答

Jim Joy
Jim Joy 2017-8-31
编辑:Jim Joy 2017-9-1
Hello Bryan,
By looking through the Bloomberg API Documentation for this field, you can see that you need to specify 'CUST_TRR_START_DT' and 'CUST_TRR_END_DT' in order to specify the time period over which you want the return. You can read about this by setting the equity to 'MSFT US Equity' in the Bloomberg Terminal, selecting the 'Fields' option, and searching for 'CUST_TRR_RETURN_HOLDING_PER'.
With this in mind, it is necessary to override these values in your Bloomberg query. The documentation linked below shows how to do this: https://www.mathworks.com/help/datafeed/blp.getdata.html#bt79nr9-1
The MATLAB Command that performs this is written below:
>> getdata(c,'MSFT US Equity',...
'CUST_TRR_RETURN_HOLDING_PER',...
{'CUST_TRR_START_DT','CUST_TRR_END_DT'},...
{'20080901','20090901'})
ans =
CUST_TRR_RETURN_HOLDING_PER: -9.7714

更多回答(1 个)

Bryan Wang
Bryan Wang 2017-9-1
Thank you Jim for your reply. this is super helpful and totally solves my problem.
Thank you again.
regards
Bryan

类别

Help CenterFile Exchange 中查找有关 Bloomberg Desktop 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by