DSWS value currency change

How do I convert the default currency to another in DSWS API using Python?

eg. KRW in USD

Best Answer

  • James.Bright1
    Answer ✓

    Hi,

    As with any platform, the tilda function allows you to convert. X(P)~USD

    Best regards


    James

Answers

  • zoya faberov
    zoya faberov ✭✭✭✭✭

    Hello @Won Young.Jang,

    Does this previous discussion address your question as well?

  • zoya faberov
    zoya faberov ✭✭✭✭✭

    Hello @Won Young.Jang,

    Please also refer to infobase reference on this subject.

  • zoya faberov
    zoya faberov ✭✭✭✭✭

    Hello @Won Young.Jang,

    Try

    ds.get_data(tickers='VOD, KO:SGL', fields=['X(P)~USD'], start='-1M', freq='D')

    Let us know how this works for you


  • zoya faberov
    zoya faberov ✭✭✭✭✭

    Hello @Won Young.Jang,

    Please post the results from running exactly as per below?

    ds.get_data(tickers='VOD, KO:SGL', fields=['X(P)~USD'], start='-1M', freq='D') 

    For comparison my result was

    InstrumentVODKO:SGLFieldX(P)~USDX(P)~USDDates

    2020-04-061.4339.622020-04-071.4240.622020-04-081.3739.812020-04-091.4140.262020-04-101.4140.382020-04-131.4139.662020-04-141.4140.252020-04-151.3540.252020-04-161.3339.882020-04-171.3642.202020-04-201.3841.042020-04-211.3040.052020-04-221.3240.462020-04-231.3340.542020-04-241.3539.942020-04-271.3740.662020-04-281.4140.892020-04-291.4841.042020-04-301.4141.042020-05-011.3841.042020-05-041.3639.462020-05-051.4039.462020-05-061.3940.26