xeroc/bitshares-pricefeed

BTS/CNY feed is off relative to BTS/USD

wmbutler opened this issue · 0 comments

After some pretty basic calculations, it appears that your CNY calculation is heavily flawed. I went through the code but can't follow the logic.

+--------+------------+--------------+--------------+---------------------+---------------------+----------------------+--------------+----------------------+--------+--------+----------------------+---------------------+
| symbol | collateral |  new price   |     cer      |         mean        |        median       |      wgt. avg.       | wgt. std (#) |      blockchain      |  mssr  |  mcr   |    my last price     |     last update     |
+--------+------------+--------------+--------------+---------------------+---------------------+----------------------+--------------+----------------------+--------+--------+----------------------+---------------------+
|  GBP   |    BTS     | 0.0625304430 | 0.0656569651 | 0.0595669234 (4.98) | 0.0625304430 (0.00) | 0.0576336306 (8.50)  |  0.79 (60)   | 0.0628170735 (-0.46) | 110.0% | 175.0% | 0.0670462633 (-6.74) | 14:14:35.204235 ago |
|  USD   |    BTS     | 0.0816662452 | 0.0857495575 | 0.0816662452 (0.00) | 0.0816662452 (0.00) | 0.0816662452 (0.00)  |  0.00 ( 1)   | 0.0824159991 (-0.91) | 110.0% | 175.0% | 0.0845249894 (-3.38) | 14:14:29.303468 ago |
|  TRY   |    BTS     | 0.3177479207 | 0.3336353167 | 0.3026485896 (4.99) | 0.3177479207 (0.00) | 0.2928259577 (8.51)  |  4.01 (60)   | 0.3222144045 (-1.39) | 110.0% | 175.0% | 0.3411752928 (-6.87) | 14:14:26.402634 ago |
|  CAD   |    BTS     | 0.1043448373 | 0.1095620792 | 0.0993849601 (4.99) | 0.1043448373 (0.00) | 0.0961593951 (8.51)  |  1.32 (60)   | 0.1052701491 (-0.88) | 110.0% | 175.0% | 0.1117687230 (-6.64) | 14:14:38.501839 ago |
|  MXN   |    BTS     | 1.5688823519 | 1.6473264695 | 1.4939024084 (5.02) | 1.5688823519 (0.00) | 1.4454167902 (8.54)  |  19.80 (60)  | 1.5818809981 (-0.82) | 110.0% | 175.0% | 1.6840551181 (-6.84) | 14:14:44.601015 ago |
|  JPY   |    BTS     | 9.3175830510 | 9.7834622035 | 8.8749072189 (4.99) | 9.3175830510 (0.00) | 8.5868714863 (8.51)  | 117.62 (90)  | 9.3505787956 (-0.35) | 110.0% | 175.0% | 9.9729729730 (-6.57) | 14:14:47.700147 ago |
| RUBLE  |    BTS     | 4.8864713175 | 5.1307948834 | 4.6554199689 (4.96) | 4.8864713175 (0.00) | 4.5043802523 (8.48)  |  61.72 (60)  | 5.0575516842 (-3.38) | 110.0% | 175.0% | 5.2258296176 (-6.49) | 14:14:53.799999 ago |
|  CHF   |    BTS     | 0.0815972341 | 0.0856770958 | 0.0776985801 (5.02) | 0.0815972341 (0.00) | 0.0751771527 (8.54)  |  1.03 (60)   | 0.0817862464 (-0.23) | 110.0% | 175.0% | 0.0875474083 (-6.80) | 14:14:32.899237 ago |
|  AUD   |    BTS     | 0.1074076217 | 0.1127780027 | 0.1022953996 (5.00) | 0.1074076217 (0.00) | 0.0989748166 (8.52)  |  1.36 (60)   | 0.1081220077 (-0.66) | 110.0% | 175.0% | 0.1150904920 (-6.68) | 14:14:59.998345 ago |
|  BTC   |    BTS     | 0.0000129530 | 0.0000136006 | 0.0000126621 (2.30) | 0.0000129530 (0.00) | 0.0000116013 (11.65) |  0.00 (19)   | 0.0000124032 (4.43)  | 110.0% | 175.0% | 0.0000122074 (6.11)  | 14:14:57.097502 ago |
|  CNY   |    BTS     | 0.5066087100 | 0.5319391455 | 0.5066087100 (0.00) | 0.5066087100 (0.00) | 0.5103365741 (-0.73) |  0.57 ( 2)   | 0.5419346622 (-6.52) | 110.0% | 175.0% | 0.5211226429 (-2.79) | 14:14:42.196564 ago |
|  EUR   |    BTS     | 0.0701477364 | 0.0736551232 | 0.0670469616 (4.62) | 0.0701477364 (0.00) | 0.0646981626 (8.42)  |  0.88 (134)  | 0.0699471854 (0.29)  | 110.0% | 175.0% | 0.0699471854 (0.29)  | 14:14:51.196722 ago |
+--------+------------+--------------+--------------+---------------------+---------------------+----------------------+--------------+----------------------+--------+--------+----------------------+---------------------+

screen shot 2017-11-14 at 11 14 33 am

.081666 / .15 = .05444

But your feed for bts/cny is showing as: .5066