we are using TRCC to contribute our quotes to Reuters. But we've found the ask/bid size shown the quote page on Eikon is 1/10 of what we want to publish. For example, if ask size is 10 for the input, the quote page shows 1.

Here's my code to set the ask and bid size.

FieldList nestedFieldList = EmaFactory.createFieldList();nestedFieldList.add(EmaFactory.createFieldEntry().realFromDouble(393, bid, OmmReal.MagnitudeType.EXPONENT_NEG_1));nestedFieldList.add(EmaFactory.createFieldEntry().realFromDouble(275, ask, OmmReal.MagnitudeType.EXPONENT_NEG_1));nestedFieldList.add(EmaFactory.createFieldEntry().real(791, bidSize*10,OmmReal.MagnitudeType.EXPONENT_NEG_1));nestedFieldList.add(EmaFactory.createFieldEntry().real(985, askSize*10,OmmReal.MagnitudeType.EXPONENT_NEG_1));

Comment

Best Answer

**OMMReal **is a structure that represents decimals or fractional values. It preserves the precision of numeric values by separating the numeric value from any decimal point or fractional denominator.

Converting an **OMMReal **to a double or float is typically done to perform calculations or display data after receiving it. The following shows the conversion of OMMReal to Double when the magnitude type of **OMMReal **is **E****XPONENT_NEG_1 (10^-1)**.

Eikon converts OMMReal to Double and then displays the double value.

If you want to preserve the value of mantissa (long), you can use the **EXPONENT_0 **magnitude type.

createFieldEntry().real(791, bidSize*10,OmmReal.MagnitudeType.EXPONENT_0))

Hello @pinzhang.wang,

It appears that you are adding fields to the nested field list as OmmReal.MagnitudeType of "EXPONENT_NEG_1", is this what you mean to include? Meaning "1 over value in power"? Or is what you would like to specify OmmReal.MagnitudeType.EXPONENT_POS_1, meaning "include value as is"?

Add to your watch list to receive emailed updates for this question. Too many emails?
Change your settings >

- Anonymous
- Sign in
- Create
- Ask a question
- Spaces
- Alpha
- App Studio
- Block Chain
- Bot Platform
- Calais
- Connected Risk APIs
- DSS
- Data Fusion
- Data Model Discovery
- Datastream
- Eikon COM
- Eikon Data APIs
- Elektron
- Legal One
- Messenger Bot
- Messenger Side by Side
- ONESOURCE
- Open PermID
- Org ID
- PAM
- ProView
- ProView Internal
- Product Insight
- Project Tracking
- Refinitiv Data Platform
- Rose's Space
- Screening
- Side by Side Integration API
- TR Knowledge Graph
- TREP APIs
- TREP Infrastructure
- TRIT
- TRKD
- TRTH
- Thomson One Smart
- Transactions
- Velocity Analytics
- Wealth Management Web Services
- World-Check Data File
- Explore
- Tags
- Questions
- Badges