Solved

Can you round to the nearest even number using AttributeRounder or CoordinateRounder?


Badge +1

Hi, I would like to round a elevation value to the nearest even number. Is there a way to do this, perhaps using AttributeRounder or CoordinateRounder?

I am using FME Desktop 2016.

Thanks

icon

Best answer by redgeographics 11 July 2017, 12:27

View original

5 replies

Userlevel 2
Badge +17
Does the elevation value have decimal places?

 

 

Badge +1
Does the elevation value have decimal places?

 

 

Hi Takashi, Yes it does have decimal places. Thanks

 

Userlevel 5
Badge +25

If you use the expression @round(@Value(attr)/2)*2 in an AttributeManager or AttributeCreator it should do the trick.

Userlevel 2
Badge +17
Oops, my question was stupid. I wanted to ask whether the resulting elevation should have decimal places, but "even" number is usually an integer. @redgeographics suggested the way to go.

 

Badge +1

Thanks guys, @redgeographicsanswer worked !

 

Reply