楼主: fengyg
466 0

[公告] 量化投资实践专栏(21) - 2 [推广有奖]

  • 0关注
  • 17粉丝

大师

27%

还不是VIP/贵宾

-

威望
0
论坛币
4161 个
通用积分
568.2622
学术水平
11 点
热心指数
24 点
信用等级
11 点
经验
7153 点
帖子
12156
精华
0
在线时间
9561 小时
注册时间
2005-10-23
最后登录
2024-4-26

楼主
fengyg 企业认证  发表于 2019-9-15 14:25:07 |只看作者 |坛友微信交流群|倒序 |AI写论文
相似文件 换一批

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
续上一贴


Obtaining the indicators

Now that that the cycles have been isolated it is time to obtain our indicators which include:

1) A projection line based on past price history

2) A de-trended zigzag neural network model to help us depict turning points

3) An up/down percent neural network model to help us in knowing which parts of the cycle are most profitable

4) A volatility neural network model to tell us which parts of the cycle are likely to be most volatile


One critical factor needs to be addressed before calculating our models and that is the length on which all the models above will be based. Due to the principle of variation the past price history on which the four models are based need to be adjusted to the approximate length of the cycle being forecasted. There are several way one can approximate the upcoming cycle:

1) Based on the current average of the cycle being forecasted the shorter the sample number the better (last 3 cycles, 5 cycles, 8 cycles etc)

2) Based only on the last cycle (The is sometimes chosen due to the fact that periods of cycles change slowly with time)

3) Based on the ratio of the same cycle to the one that preceded it or the mean ratio (last X cycles) under a similar cyclical circumstance although we need a significant amount of historical data to chose this method.

l  20 week ratio – find its counterparts ratio with its preceding cycle or mean ratio in the previous 54 month cycle

l  40 week ratio - find its counterparts ratio with its preceding cycle or mean ratio in the previous 9 year cycle

l  18 month ratio - find its counterparts ratio with its preceding cycle or mean ratio in the previous 18 year cycle

l  54 month ratio - find its counterparts ratio with its preceding cycle or mean ratio in the previous 54 year cycle

l  9 year ratio - find its counterparts ratio with its preceding cycle or mean ratio in the previous 162 year cycle ratio

l  Etc.

4) Find the ratio of the minor cycles of the current cycle with the cycle’s most recent counterpart’s minor cycles then multiply the cycle’s counterparts length by the ratio in order to estimate the length of the cycle being forecast (allow a lead/lag window in case the phasing is not 100% accurate) This is done to obtain the highest possible correlation with what has already passed of the current cycle or just before its beginning. This is the preferred way to obtain an approximate of the current cycle’s length. (One can code the computer to automatically alter the cycle’s most recent counterpart’s length and project it from the appropriate low with a certain lead/lag window in order to obtain the highest possible correlation with what has passed of the cycle or just prior. The rest of the cycle will remain in high correlation with the projection line (superposition of the cycle’s counterparts of modified length) as presented below.



Farghaly-Method-Timing Solution8.bmp




After choosing the appropriate method in determining the approximate length of the upcoming cycle. It is now time to start clipping parts of the price history. We first need to determine which cycle we are in to know which parts of the price history we are interested in. We know from the phasing analysis above that we are currently in the first 18 month cycle of the first 54 month cycle of the first 9 year cycle of the 18 year cycle. Now that we know where we are in the hierarchy of cycles we would go back in history in order to clip the first 18 month cycle of the 18 year cycle in the past (similar cyclical circumstance) this can be done by setting Tmin/Tmax from the beginning to the end of each individual cycle then right click and save the chart as text. We will use the cycles extracted as an input for our indicators. Keep in mind that the cycles isolated will be of slightly different lengths due to the principle of variation. We should now do the following steps:

1) Extend or shrink the cycles evenly to match our approximation of the length of the cycle we are forecasting (if isolated correctly once overlayed will be very similar after unifying the length)

2) Form an algebraic sum of the cycles (which should now be of equal length) which will be used to aid us in determining the direction of the market under consideration

3) Append the individual cycles into one continuous series

4) Load up the algebraic sum as an additional chart or load it up in the inter-market analysis portion of ‘pattern’ for statistical analysis or back testing. Make sure you select the coincide index

5) Load the appended series and extract the cycle with how many overtones you wish even if there is no peak in the periodogram then copy it into the clipboard

6) Run the neural network module and select the de-trended zigzag, volatility & up/down percent as outputs. Use what is in the clipboard as an input and train on all pervious bars.



Farghaly-Method-Timing Solution9.bmp




We are only using two periods in our calculations hence spectral analysis was unable to pick up the cycle. We know that it is present so we can select the period manually and move the selected cycle with the amount of overtones required into the clipboard. Open the neural network module and choose the cycles as the input and whichever indicator you chose as an output. The accuracy of your results will be astonishing for the following reasons:

1) We chose the cycles that are most similar in context of the larger cycles hence the trend component is very similar

2) We unified their length and matched it to the approximate length of the upcoming cycle to make sure the calculations are as close to accurate as possible

3) The projection line obtained syncs up the smaller cycles of the cycles under a similar cyclical circumstance in order for them to match the smaller cycles within the cycle we are attempting to forecast hence the correlation coefficient should be quite high



Farghaly-Method-Timing Solution10.bmp


捕获5.PNG

Farghaly-Method-Timing Solution11.bmp

Farghaly-Method-Timing Solution12.bmp

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

关键词:量化投资 Calculations Approximate correlation Determining

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注jr
拉您进交流群

京ICP备16021002-2号 京B2-20170662号 京公网安备 11010802022788号 论坛法律顾问:王进律师 知识产权保护声明   免责及隐私声明

GMT+8, 2024-4-27 07:03