经常被几个问题困扰着:
1. 究竟开发一个交易软件用什么软件最好? c++, java, c#, Python
经常得到的一般答案是C++适合用来性能好(低延迟)的交易软件,c#适合用来做window平台的交易软件, Python是现在开发交易软件的趋势
那么要做GUI吗?什么是最好的架构?可扩展性好具体表现在哪些方面?一堆问题都没有肯定的答案
2. 为什么FXCM要用Lua来开发交易软件?
究竟什么是lua? 头好晕
下载了SDK,打开了RSI指标来研究
定义函数
function Init()
end
python def init() { }
mql4: void init() { }
c# private void init() { }
indicator:name(resource:get("name");
indicator.parameters:addGroup("Calculation")
string.format()
core.rgb(255,0,0);
: 表示什么?
. 表示什么?
按F1,居然什么都没有,晕圈
-- 注释
定义变量:无需定义变量类型
local n;
local source = nil; --nil 应该表示空
RSI = instance:addStream("RSI", core.Line, name, "RSI", instance.parameters.clrRSI, first);
RSI:setWidth
RSI:setStyle
RSI:setPrecision(2);
RSI:addLevel(0);
看到这里,RSI可能是class,或者interface, 猜测
:用来表示方法
. 用来表示属性
猜测
一个指标文件的结构
function init() indicator profile initialization
indicator:name
indicator:description
indicator:requiredSource
indicator:type
indicator.parameter:addInteger
function Update(period)
function Prepare()
static public method
get
put
statement
chunks: a sequence of statements
API
晕死,基本看不懂,