| Author |
Message |
![[Post New]](/community/templates/default/images/icon_minipost_new.gif) 18/03/2009 17:09:35
|
uschles
Joined: 18/03/2009 13:44:45
Messages: 15
Offline
|
Hi there,
Are there any simple programmatic examples that utilize the API to do simple stuff? For example, enter a simple order into MTS? I'd rather be able to use my own interface than have to study and greatly tweak an existing application (such as Strategy Agent) which I may not need.
Thanks,
Udi
|
|
|
 |
![[Post New]](/community/templates/default/images/icon_minipost_new.gif) 23/03/2009 21:54:53
|
colin
Joined: 23/03/2009 21:35:49
Messages: 449
Offline
|
Here's a brief Java example:
Apologies about any compilation errors, I wrote this from the top of my head, but it should give you the general idea. This strategy, when started, requests market data for a few symbols from the in-memory simulated market data provider. It then sends contra orders for any quote it receives. Naturally, this example is brain-dead but should give an idea on how to send orders. Please let me know if you would like further elaboration.
This message was edited 1 time. Last update was at 24/03/2009 09:38:08
|
|
|
 |
![[Post New]](/community/templates/default/images/icon_minipost_new.gif) 24/03/2009 09:49:24
|
ytalmor
Joined: 12/02/2009 00:24:08
Messages: 130
Offline
|
Also check this short documentation that provides an overview of how to use our client API:
http://www.marketcetera.org/confluence/display/MDN/ORS+Client+-+Connecting+Applications+to+Marketcetera
As the documentation mentions, OrderLoader is a simple client you can use as a reference/example of how to send orders to MTS.
Note that the client APIs are meant for basic interaction with MTS and are "lower level API" compared to our strategy API. Also, the client API are not stable yet so it might change between minor releases (though we do try to maintain backward compatibility).
Thanks,
Yoram
|
|
|
 |
![[Post New]](/community/templates/default/images/icon_minipost_new.gif) 24/03/2009 14:18:35
|
uschles
Joined: 18/03/2009 13:44:45
Messages: 15
Offline
|
Thanks, Yoram, for the advice. Though at the moment I'm more interested in utilizing the strategyagent class programatically to use my own strategies. The document I find doesn't go to the code level at all ( http://www.marketcetera.org/confluence/display/SA/Strategy+Agent ). Is there a way/example that can help demonstrate how this can be done? Or is this something you don't recommend, and we are advised to stick with the premade version of StrategyAgent?
Thanks,
Udi
ytalmor wrote:Also check this short documentation that provides an overview of how to use our client API:
http://www.marketcetera.org/confluence/display/MDN/ORS+Client+-+Connecting+Applications+to+Marketcetera
As the documentation mentions, OrderLoader is a simple client you can use as a reference/example of how to send orders to MTS.
Note that the client APIs are meant for basic interaction with MTS and are "lower level API" compared to our strategy API. Also, the client API are not stable yet so it might change between minor releases (though we do try to maintain backward compatibility).
Thanks,
Yoram
This message was edited 1 time. Last update was at 24/03/2009 14:52:36
|
|
|
 |
![[Post New]](/community/templates/default/images/icon_minipost_new.gif) 24/03/2009 16:33:01
|
ytalmor
Joined: 12/02/2009 00:24:08
Messages: 130
Offline
|
The reason I mentioned client API is because I wasn't sure what are the set of problems you are trying to address. Strategyagent is our recommended way of deploying strategies. We have a few very basic examples packaged with Strategyagent that you can check out and the above example posted by Colin should help you as well. Beyond that it is just going through our strategy API Javadocs or here and writing your own strategy.
Hopefully that will help. Please let us know if you have specific questions/examples you are looking for.
Thanks,
Yoram
|
|
|
 |
![[Post New]](/community/templates/default/images/icon_minipost_new.gif) 24/03/2009 16:35:08
|
colin
Joined: 23/03/2009 21:35:49
Messages: 449
Offline
|
Not sure, but I think the issue may not be around authoring strategies, but invoking them. That is, I believe OP thought that it was possible to author a strategy and run it as a standalone application, i.e. outside of the Strategy Agent or Photon.
|
|
|
 |
![[Post New]](/community/templates/default/images/icon_minipost_new.gif) 24/03/2009 16:38:57
|
uschles
Joined: 18/03/2009 13:44:45
Messages: 15
Offline
|
Thanks Yoram and Colin for the quick responses.
Yes, exactly: designing a strategy seems like a rather straightforward process. I just want to be able to run it, first in my own instance of the server and then your simulator (and later on, our real broker - but I'm not there just yet). So far I've been unable to tweak to get obtain this result, even though I am positive it is easy if one knows how.
Will greatly appreciate any help in the right direction.
Thanks,
Udi
|
|
|
 |
|
|