Merge pull request #768 from julian-molina/develop
Contribution: LF Trading Bot Data Structures Revision
This commit is contained in:
5 files changed
+117
-80
No files matched your search
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"type": "Default Exchange",
|
||||
"definition": {
|
||||
"text": "The Default Exchange is the one referenced by the Exchange Data Tasks, Exchange Trading Tasks, Exchange Learning Tasks nodes of which a certain Task decends from. The Trading Bot running inside that Task will considere that referenced exchange to be it's Default Exchange.",
|
||||
"updated": 1612352828045
|
||||
"text": "The Default Exchange is the one referenced by the Exchange Data Tasks, Exchange Trading Tasks, and Exchange Learning Tasks nodes from which a certain Task descends. The Trading Bot Instance running under that Task will consider the referenced Crypto Exchange to be the Default Exchange for the said Task.",
|
||||
"updated": 1617616790868
|
||||
},
|
||||
"paragraphs": [
|
||||
{
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"type": "Tutorial",
|
||||
"definition": {
|
||||
"text": "The tutorial hierarchy features a free arrangement of Tutorial Topic and Tutorial Step nodes that make up a tutorial. Each node in the hierarchy, including the parent tutorial node, represents an HTML page that is overlaid on top of both the design space and the charting space.",
|
||||
"updated": 1613839026788
|
||||
"text": "The tutorial hierarchy features a free arrangement of Tutorial Topic and Tutorial Step nodes that make up a tutorial. Each node in the hierarchy, including the parent tutorial node, represents an HTML page that may be overlaid on top of both the Design Space and the Charting Space.",
|
||||
"updated": 1617610222444
|
||||
},
|
||||
"paragraphs": [
|
||||
{
|
||||
@@ -11,18 +11,23 @@
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "Nodes in the hierarchy may be arranged freely, meaning that there may be as many tutorial topics and tutorial steps as desired. ",
|
||||
"updated": 1613839088895
|
||||
"text": "Nodes in the hierarchy may be arranged freely, meaning that there may be as many tutorial topics and tutorial steps as desired. Tutorial topics may contain tutorial steps but also tutorial topics. This allows nesting topics to use them as subtopics.",
|
||||
"updated": 1617610249818
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "In general terms, all types of nodes behave similarly in the sense that each node, independently of the precise type, represents a tutorial step in and of itself. Subtle differences shall be covered where appropriate.",
|
||||
"updated": 1613839117191
|
||||
"text": "The system – as usual – reads the hierarchy in a clockwise direction starting from the node to the right of the parent Tutorial node, and goes to the depest point of each branch before moving to the next one.",
|
||||
"updated": 1617609961401
|
||||
},
|
||||
{
|
||||
"style": "Success",
|
||||
"text": "The key similarity among all types of nodes in the hierarchy is that all of them may draw content from a tutorial page in the Docs.",
|
||||
"updated": 1613839286982
|
||||
"style": "Text",
|
||||
"text": "In general terms, all types of nodes behave similarly in the sense that each node, independently of the precise type, represents a Tutorial Step in and of itself. Subtle differences shall be covered where appropriate.",
|
||||
"updated": 1617609984716
|
||||
},
|
||||
{
|
||||
"style": "Note",
|
||||
"text": "The key similarity among all types of nodes in the hierarchy is that all of them may draw content from the tutorial's collection of pages in the Docs. That is, each node in the hierarchy points to a page in the Docs, and it is that page in the Docs that features the content that tutorials display. The pointer is specified in the configuration of each node (see the docs property).",
|
||||
"updated": 1617611604392
|
||||
},
|
||||
{
|
||||
"style": "Block",
|
||||
@@ -35,18 +40,18 @@
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "The configuration of each node in the tutorial hierarchy determines the content and behavior of each step. All types of nodes share the same basic configuration. However, Tutorial Step nodes have extra properties, described elsewhere.",
|
||||
"updated": 1613839329036
|
||||
"text": "The configuration of each node in the tutorial hierarchy determines the content and behavior of each step. All types of nodes share the same basic configuration. However, Tutorial Step nodes have extra properties, described on the Tutorial Step node page.",
|
||||
"updated": 1617610392929
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "The layout of the HTML page follows the layout of the referenced page in the Docs, although displayed within the confines of the tutorial window. ",
|
||||
"updated": 1613839417342
|
||||
"text": "The layout of the HTML page follows the layout of the associated page in the Docs, although displayed within the confines of the tutorial window.",
|
||||
"updated": 1617610416865
|
||||
},
|
||||
{
|
||||
"style": "Callout",
|
||||
"text": "In other words, you affect the layout of the step by writing content and applying styles to individual paragraphs in the associated Docs Page.",
|
||||
"updated": 1613839489189
|
||||
"text": "In other words, you affect the layout of the particular step by writing content and applying styles to individual paragraphs in the associated Docs Page.",
|
||||
"updated": 1617610435932
|
||||
},
|
||||
{
|
||||
"style": "Note",
|
||||
@@ -60,18 +65,33 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "icon: the name and project of one of the icons stored in the \\Projects\\[Project-Name]\\Iconsfolder, without the extension. When the configuration exists, the icon is placed within a table, on the left-hand side of the text block featured in the definition field. When there is no icon, the definition occupies the full width.",
|
||||
"updated": 1613840648780
|
||||
"text": "icon: Features the name of the icon without the extension, and the project the icon belongs to. For your reference, icons are stored in the following path:",
|
||||
"updated": 1617610705494
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
"text": "\\Projects\\[Project-Name]\\Icons",
|
||||
"updated": 1617610685030
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "When the configuration exists, the icon is placed within a table, on the left-hand side of the text block featured in the definition field of the corresponding Docs page. When there is no icon, the definition occupies the full width.",
|
||||
"updated": 1617610852528
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
"text": "\"icon\": {\n \"name\": \"balance\",\n \"project\": \"Superalgos\"\n }",
|
||||
"updated": 1613840669552
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "The above configuration places the balance.png icon of the Superalgos project in the table of the corresponding Docs page.",
|
||||
"updated": 1617610921825
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "position: determines the position of the floating HTML. There are three alternatives... \"Left\", \"Right\", or leave the field empty to position the page in the center of the screen.",
|
||||
"updated": 1613842749882
|
||||
"text": "position: Determines the position of the floating HTML. There are three alternatives... \"Left\", \"Right\", or leave the field empty to position the page in the center of the screen.",
|
||||
"updated": 1617610967355
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -80,8 +100,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "slider: determines the position of the horizontal slider. There are three alternatives... \"toTop\", \"toBottom\", \"toMiddle\".",
|
||||
"updated": 1613842783566
|
||||
"text": "slider: Determines the position of the horizontal slider. There are three alternatives... \"toTop\", \"toBottom\", \"toMiddle\".",
|
||||
"updated": 1617610973439
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -89,18 +109,28 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "pressButton: allows you to forcefully \"Stop\" the tutorial, go to the \"Next\" step, go to the \"Previous\" step, or \"Skip\" a step. When a step is loaded and one of these options is configured in this property, the action is applied immediately. A common use of this feature is to skip a step, for instance, a Tutorial Topic node that is used solely for organizational purposes within the hierarchy, thus has no content.",
|
||||
"updated": 1613842824873
|
||||
"text": "pressButton: Allows you to forcefully \"Stop\" the tutorial, go to the \"Next\" step, go to the \"Previous\" step, or \"Skip\" a step. When a step is loaded and one of these options is configured in this property, the action is applied immediately. A common use of this feature is to skip a step, for instance, a Tutorial Topic node that is used solely for organizational purposes within the hierarchy, thus has no content.",
|
||||
"updated": 1617611004815
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
"text": "\"pressButton\": \"Next\"",
|
||||
"updated": 1613841332185
|
||||
},
|
||||
{
|
||||
"style": "Success",
|
||||
"text": "You may use Tutorial Topic nodes for organizational purposes only, for instance, to arrange the hierarchy in a way that it's easy to maintain. Topics with too many steps are harder to deal with later on. In other words, you may use a Tutorial Topic node to group several steps, even if you don't intend the Tutorial Topic node to display any content. In such cases, you may use this property to skip the step that is not intended for content-display.",
|
||||
"updated": 1617611332634
|
||||
},
|
||||
{
|
||||
"style": "Note",
|
||||
"text": "Leave the filed empty for the step to play in the usual fashion.",
|
||||
"updated": 1617611454046
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "docs: the property is used to reference the Docs Tutorial Page that feeds content to the particular tutorial step. The definition requires the name of the Project, the Docs Page Category which is always Tutorial, and the complete name of the tutorial step page.",
|
||||
"updated": 1613841395148
|
||||
"text": "docs: The property is used to point to the Docs Tutorial Page that feeds content to the particular tutorial step. The definition requires the name of the Project, the Docs Page Category which is always Tutorial, and the complete name of the Tutorial Step page.",
|
||||
"updated": 1617611566144
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
|
||||
+34
-22
@@ -3,14 +3,14 @@
|
||||
"pageNumber": "1",
|
||||
"type": "LF Trading Bot - Chart Data Structure",
|
||||
"definition": {
|
||||
"text": "The Chart Data Structure is an object that contains Indicator or Sensor bots data, available at runtime, that can be accessed from the code of Conditions and Formulas.",
|
||||
"updated": 1612349390525
|
||||
"text": "The Chart Data Structure is an object that contains Indicator Bot or Sensor Bot data available at runtime, and can be accessed from the code of Conditions and Formulas.",
|
||||
"updated": 1617615874508
|
||||
},
|
||||
"paragraphs": [
|
||||
{
|
||||
"style": "Note",
|
||||
"text": "This Javascript object, together with the other two data structures available, ultimately defines the syntax that can be used to write conditions and formulas, and more precisely the sintax to retrieve Indicator Bot and Sensor Bot data.",
|
||||
"updated": 1612349521002
|
||||
"text": "This Javascript object, together with the other two data structures described on this topic, ultimately defines the syntax that used to write conditions and formulas, and more precisely the syntax to retrieve Indicator Bot and Sensor Bot data.",
|
||||
"updated": 1617615932665
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
@@ -18,8 +18,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "The root of the object is called...",
|
||||
"updated": 1612351077417
|
||||
"text": "The root of the object is...",
|
||||
"updated": 1617615941456
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -27,8 +27,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "After it these are it's valid properties...",
|
||||
"updated": 1612351085368
|
||||
"text": "After the root, the definition of the timeframe is mandatory...",
|
||||
"updated": 1617616001919
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -37,13 +37,13 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "After that, it is expected the singleVariableName defined at the config of the Product Definition of an Indicator or Sensor.",
|
||||
"updated": 1612351093008
|
||||
"text": "After that comes the singleVariableName defined at the config of the Product Definition of an Indicator Bot or Sensor Bot.",
|
||||
"updated": 1617616054644
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "Finally the last property must be the codeName of a Record Property Node, belonging to the same Product Definition mentioned earlier.",
|
||||
"updated": 1612350081190
|
||||
"text": "Finally, the last property is the codeName of a Record Property node, corresponding to the same Product Definition mentioned earlier.",
|
||||
"updated": 1617616859394
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
@@ -51,47 +51,59 @@
|
||||
"updated": 1612350235632
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "chart.at01min.support.support5Rate",
|
||||
"updated": 1612349808636
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "chart.at05min.candle.open",
|
||||
"updated": 1612350213519
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "chart.at24hs.bollingerBand.movingAverage"
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
"text": "Advance Usage"
|
||||
"text": "Advanced Use",
|
||||
"updated": 1617616121116
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "You also have access to the set of indicators objects loaded in memory though this same data structure. If instead of using the sinleVariableName you use the pluralVariableName what you get is an array of objects, that depending on the time frame, could be the object for that time frame of all market or the current and previous day for time frames < 1 hour.",
|
||||
"updated": 1612353614216
|
||||
"text": "You also have access to the set of indicator objects loaded in memory through this same data structure.",
|
||||
"updated": 1617616255365
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "If instead of using the singleVariableName you use the pluralVariableName, you get an array of objects that — depending on the time frame — could be the object featuring the whole market (for time frames of one hour and above) or the current and previous day (for time frames below one hour).",
|
||||
"updated": 1617616419121
|
||||
},
|
||||
{
|
||||
"style": "Note",
|
||||
"text": "Remember that time frames of one hour and above are stored as Market Files while time frames below one hour are stored as Daily Files."
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
"text": "Examples"
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "chart.at05min.candles"
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "Will return an array of candles of the previous day concatenated with the candles of the current day. You then can use this information as you wish."
|
||||
"text": "The above returns an array of candles of the previous days concatenated with the candles of the current day. You may use this information as you wish.",
|
||||
"updated": 1617616467792
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "chart.at24hs.bollingerBands"
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "Will return an array of all bollingerBands object of the whole market, since the time frame is >= 1 hour."
|
||||
"text": "The above returns an array of all bollingerBands object of the whole market since the time frame is above 1 hour.",
|
||||
"updated": 1617616877744
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
|
||||
+13
-16
@@ -3,22 +3,18 @@
|
||||
"pageNumber": "2",
|
||||
"type": "LF Trading Bot - Market Data Structure",
|
||||
"definition": {
|
||||
"text": "The Market Data Structure is one of the 3 data structures available at Conditions and Formulas with data from Indicator and Sensor bots.",
|
||||
"updated": 1612351166683
|
||||
"text": "You may use this Javascript object from within conditions and formulas when you want to specify a Market different from the Default Market. For example, you may access data of the ETH/USDT market from a Trading System running on the BTC/USDT market.",
|
||||
"updated": 1617617047716
|
||||
},
|
||||
"paragraphs": [
|
||||
{
|
||||
"style": "Note",
|
||||
"text": "This Javascript object can be used when you want to specify a market which is different fomr the Default Market. In this way you can access data of the ETH/USDT market from a stragegy running for example at the BTC/USDT market.",
|
||||
"updated": 1612351365558
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
"text": "Structure"
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "The root of the object is called..."
|
||||
"text": "The root of the object is...",
|
||||
"updated": 1617617057256
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -27,8 +23,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "After it you need to spacify the codeName of an Asset representing the Market Base Asset, like the following...",
|
||||
"updated": 1612351559165
|
||||
"text": "Then you must specify the codeName of an Asset representing the Market Base Asset, as follows...",
|
||||
"updated": 1617617165183
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -37,7 +33,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "After that again the codeName of an Asset but this time representing the Market Quoted Asset.."
|
||||
"text": "After that, specify the codeName of an Asset but this time representing the Market Quoted Asset...",
|
||||
"updated": 1617617108322
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -45,8 +42,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "Finally you continue with the syntax of the LF Trading Bot - Chart Data Structure",
|
||||
"updated": 1612352138708
|
||||
"text": "Finally, continue with the syntax of the LF Trading Bot - Chart Data Structure",
|
||||
"updated": 1617617178876
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
@@ -54,17 +51,17 @@
|
||||
"updated": 1612352364588
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "market.ETH.BTC.chart.at01min.support.support5Rate",
|
||||
"updated": 1612351751906
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "market.BTC.USDT.chart.at05min.candle.open",
|
||||
"updated": 1612351782297
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "market.ETH.USDT.chart.at24hs.bollingerBand.movingAverage",
|
||||
"updated": 1612351804074
|
||||
}
|
||||
|
||||
+13
-15
@@ -3,21 +3,18 @@
|
||||
"pageNumber": "3",
|
||||
"type": "LF Trading Bot - Exchange Data Structure",
|
||||
"definition": {
|
||||
"text": "Write a summary for this topic page."
|
||||
"text": "You may use this Javascript object when you want to specify a Crypto Exchange which is different from the Default Exchange. Then you may, for example, access data from Coinbase Pro from a Trading Session running on Binance.",
|
||||
"updated": 1617617256390
|
||||
},
|
||||
"paragraphs": [
|
||||
{
|
||||
"style": "Note",
|
||||
"text": "This Javascript object can be used when you want to specify a Cryto Exchage which is different fomr the Default Exchange. In this way you can access data from Coinbase Pro from a stragegy running for example at Binance.",
|
||||
"updated": 1612351988656
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
"text": "Structure"
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "The root of the object is called..."
|
||||
"text": "The root of the object is...",
|
||||
"updated": 1617617272058
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -26,8 +23,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "After it you need to spacify the codeName of a Crypto Exchange, like the following...",
|
||||
"updated": 1612352057634
|
||||
"text": "Then, you must specify the codeName of a Crypto Exchange, for instance...",
|
||||
"updated": 1617617294733
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
@@ -36,8 +33,8 @@
|
||||
},
|
||||
{
|
||||
"style": "List",
|
||||
"text": "Finally you continue with the syntax of the LF Trading Bot - Market Data Structure",
|
||||
"updated": 1612352124926
|
||||
"text": "Finally, continue with the syntax of the LF Trading Bot - Market Data Structure",
|
||||
"updated": 1617617310038
|
||||
},
|
||||
{
|
||||
"style": "Title",
|
||||
@@ -45,17 +42,17 @@
|
||||
"updated": 1612352354839
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "exchange.poloniex.market.ETH.BTC.chart.at01min.support.support5Rate",
|
||||
"updated": 1612352167087
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "exchange.bitfinex.market.BTC.USDT.chart.at05min.candle.open",
|
||||
"updated": 1612352188098
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"style": "Json",
|
||||
"text": "exchange.binance.market.ETH.USDT.chart.at24hs.bollingerBand.movingAverage",
|
||||
"updated": 1612352200136
|
||||
},
|
||||
@@ -66,7 +63,8 @@
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "As you can see at the following example you can have a mix of chart, market and exchange usage withing the same Formula or Condition. "
|
||||
"text": "As you can see in the following example, you may have a mix of chart, market and exchange usage within the same Formula or Condition.",
|
||||
"updated": 1617617348929
|
||||
},
|
||||
{
|
||||
"style": "Json",
|
||||
|
||||
Reference in new issue
Block a user