question

Upvotes
Accepted
28 2 1 2

Is there a way in DSWS to get a time series request to automatically return the series name as the column header?

In DSWS a time series request will return the series code as the column header. Is there a way to automatically return the series name (similar to retName=True for datatypes)?

Below is an example of my request.

ds.get_data (tickers='SPXPDFU.F, SPXPDFUYR', fields=['X'], start='2000-01-01', end='2049-01-01', freq='Q')

Thanks in advance,

Alison

datastream-apidsws-api
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

@Alison.Quick

Hi,

Thank you for your participation in the forum.

Is the reply below satisfactory in answering your question?

If yes please click the 'Accept' text next to the reply. This will guide all community members who have a similar question.

Otherwise please post again offering further insight into your question.

Thanks,

AHS


1 Answer

· Write an Answer
Upvotes
Accepted
78.8k 249 52 74

@Alison.Quick

The library can't replace the column names.

However, you can rename the column name by using Python code. For more information, please refer to the answers in the thread.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Thank you so much, very helpful!

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.