Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - emski

Pages: 1 ... 11 12 13 14 15 16 17 [18] 19 20 21 22 23 24 25 ... 86
256
General Discussion / Re: publish feed price automatic(From BitSuperLab)
« on: November 25, 2014, 07:33:09 am »
have updated:

    1. need python3 now
    2.  please modify config.json,  sample file is config-sample.json
    3. now I computer feed price with weight, weight depends on depth, and scale.
        support 5 exchange: btc38, yunbi, bter, BTS USD MARKET, BTS CNY MARKET
        please use  different scale, change file config.json

The link in OP to the github repo returns 404.

257
General Discussion / Re: Escrow Passes Basic Testing
« on: November 25, 2014, 07:28:57 am »
Well Done! Keep up the good (technical) news.

258
The configuration in my version of the script allows each delegate to put different set of exchange trust levels.
Essentially this produces unique feed for any different configuration allowing every delegate to use slightly different rules.
When you add the random time between feeds you get harder to predict median.

259
Can I also point out that any price feed script should add noise to the price feed, both in when it updates (so that nobody can predict exactly when it updates) and in what price it reports (so that nobody can predict exactly what price it will report). If the bid/ask spread is 1%, a price feed script should report a random variable whose mean is the mean of the spread, but that could take any value within there.

If people don't get it I'll post a stronger justification later.

How can you validate if the delegate is trying to manipulate that?
I don't think random numbers will help. Care to elaborate ?

260
Isn't this free market?
Isn't this supposed to work this way?
My version of the script is extra sensitive to negative price movements 0.1% (at default settings) trigger feed update.

The problem is that the current price feed system does not factor in volume into the spot price, and spot price has little to do with actual valuation in an illiquid market. Look at Mastercoin's market cap, for example, vs its volume. If you were a MSC whale, you'd have a very hard time divesting at the 'spot price'.

My version of the script uses the volume reported by the exchange. If the volume is low its (that exchange's) price weight is reduced.

The only way to make more accurate script is if we collect all deals from all exchanges in the last few minutes and average everything accounting for volume and price of each trade.

261
Isn't this free market?
Isn't this supposed to work this way?
My version of the script is extra sensitive to negative price movements 0.1% (at default settings) trigger feed update.

262
I've missed this thread.
Parts of the letters are missing - win 8 64 , firefox 33.1.1 and chrome
Here is a screenshot:
https://www.dropbox.com/s/4kdp2028g0llobw/bts.png?dl=0

263
General Discussion / Re: feed price relative bid/ask order will hurt us
« on: November 19, 2014, 03:11:38 pm »
For each bitAsset you sort all active feeds in ascending order (a delegate's active feed is his last feed if its age is less than 24h).
If the sorted array of active feeds has N elements the (N+1)/2  th element is chosen as median. (Havent actually looked in the code and there could be slight difference but that is the idea)

Sorry, it still isn't clear - are you saying:

A) the median is over N different delegate feeds
B) the median is over N different feeds within one delegate

?
A)
A single delegate can have at most 1 active feed. Only the last feed from each delegate matters if it is published in the last 24 hours.

264
General Discussion / Re: feed price relative bid/ask order will hurt us
« on: November 19, 2014, 12:22:43 pm »
No, I think the actually used price feed is the median of all published ones.

Are you sure its not a median of all current feeds to the current delegate?

I'm fairly sure but maybe someone can verify it.

For each bitAsset you sort all active feeds in ascending order (a delegate's active feed is his last feed if its age is less than 24h).
If the sorted array of active feeds has N elements the (N+1)/2  th element is chosen as median. (Havent actually looked in the code and there could be slight difference but that is the idea)

265
Actually emski and Markus are wrong.

Well, I do not actually know if they are wrong, but there are smartasses that say that we cannot continue like that! And we must set a bar for the quality of the price feeds. If the price feed is below the said price feed standard (read price) it will no longer be valid (cause they said so!)

The argument goes something like this -"Do you know what will happen if the quality of price feeds go below 90% quality? They will gradually continue to decline until the reach 0, quality...", "Nobody will trust the feeds and they will eventually reach zero".

That's why we will set the standard... and no more crazy non-standard feeds will be allowed.

And it will be awesome after that! <hearts><hearts> many <hearts>


PS
And Dude, if you do not trust the quality feed theory you should go start your own blockchain, experimenting with such unsafe propositions... we are quality feed believers here (well we became such recently, but now in quality feeds we trust!)!

I'm genuinely interested in your definition of price feed quality.
What features is it supposed to have?


My idea of a perfect price feed is that:
Get all "real" trades. Average out weighting in the volume of each trade. The result is "perfect" feed.
As this is impossible due to many reasons I think a solution that takes into account the volume as well as each price of the exchanges is as good as it gets.


There are some other issues with price feeds:
1 If an exchange fails to provide its feed data and this influences significantly the feed => should we still publish the new feed or wait for the exchange to resume its feed service? (my version of the script already allows configuration of this behavior)
2 If an exchange publishes significantly higher/lower price for an asset at tiny volume => should we account that?

Currently if you want to verify my feeds you can just run the script yourself (my settings are in the repo). If you believe my script (or anyone else's) isn't accurate and should not be used => state it and explain yourself.


On the other matter you pointed out: Should we use price feeds at all? It would be a good idea if someone briefly describes all the possible alternative approaches and maybe start a discussion?

266
General Discussion / Re: feed price relative bid/ask order will hurt us
« on: November 19, 2014, 10:18:03 am »
And delegates are free to set trust_level for each exchange which is essentially a weight of that exchange's feed.

Wont that mean each delegate could have a totally different feed price?

Yes.
And that is a good thing.

267
General Discussion / Re: feed price relative bid/ask order will hurt us
« on: November 19, 2014, 07:42:25 am »
before we support this new feature, we should change the price feed logic.
It should include volume from wallet market, and the  feed price should  relative to volume.

I've included the volume in my price feed mod. See it here: https://bitsharestalk.org/index.php?topic=9698.0. It is based on xeroc's version of your script.
No single exchange can manipulate the price with low volume.
And delegates are free to set trust_level for each exchange which is essentially a weight of that exchange's feed.

268
General Discussion / Re: Yet Another Price Feed Mod
« on: November 15, 2014, 01:16:53 am »
cool, emski yours is working for me now

The error in xeroc's script you see might be related to improper config file.
There are different variables in both versions. Make sure you use proper version.

269
General Discussion / Re: Yet Another Price Feed Mod
« on: November 15, 2014, 01:00:13 am »
My bad. I've committed not working version.
Should be OK now.

270
General Discussion / Re: Yet Another Price Feed Mod
« on: November 15, 2014, 12:55:44 am »
I still get errors with both emski and xeroc's updated script:

emski:
  File "./btsx_feed.py", line 125
    volume_in_btc[ mapAsset ].append(float(result[coin.lower()+"_btc"]["vol_btc"])*confi$
                                                                                                                                           ^
SyntaxError: invalid syntax


xeroc:
  File "/home/user/feed_xeroc/btsx_feed.py", line 433, in <module>
    if publish_rule() :
  File "/home/user/feed_xeroc/btsx_feed.py", line 47, in publish_rule
    elif fabs(myCurrentFeed[asset]-realPrice[asset])/realPrice[asset] > config["change_min"] and\
KeyError: 'change_min'

What arguments are you passing to the scripts ?
Example: "./btsx_feed.py GOLD BTC USD CNY EUR"

Are you sure you have the file as in github ?

Pages: 1 ... 11 12 13 14 15 16 17 [18] 19 20 21 22 23 24 25 ... 86