Login Page - Create Account

Support Board


Date/Time: Thu, 16 Jan 2025 19:09:25 +0000



[Programming Help] - Using LRS index values

View Count: 893

[2017-11-10 22:26:08]
bala - Posts: 74
I am using LRS study to store the values of LRS at each index (using the computation in study5.cpp). I try to use the values of LRS[sc.Index],LRS[sc.Index-1],LRS[sc.Index-2]. It sees to be working fine for some values and suddenly the index-1 and index-2 take the price values. PLease check the log lines
LOG:

Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 0, LRS -0.000000,LRS_1 -0.000000, LRS_2 -0.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 1, LRS -0.000000,LRS_1 -0.000000, LRS_2 -0.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 2, LRS 0.025000,LRS_1 -0.000000, LRS_2 -0.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 3, LRS 0.046429,LRS_1 0.025000, LRS_2 -0.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 4, LRS 0.064286,LRS_1 0.046429, LRS_2 0.025000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 5, LRS 0.084821,LRS_1 0.064286, LRS_2 0.046429 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 6, LRS 0.113393,LRS_1 0.084821, LRS_2 0.064286 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 7, LRS 0.129464,LRS_1 0.113393, LRS_2 0.084821 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 8, LRS 0.127679,LRS_1 0.129464, LRS_2 0.113393 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 9, LRS 0.134821,LRS_1 0.127679, LRS_2 0.129464 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 10, LRS 0.136607,LRS_1 1002.000000, LRS_2 0.127679 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 11, LRS 0.133036,LRS_1 0.136607, LRS_2 1002.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 12, LRS 0.124107,LRS_1 0.133036, LRS_2 0.136607 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 13, LRS 0.097321,LRS_1 0.124107, LRS_2 0.133036 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 14, LRS 0.023214,LRS_1 0.097321, LRS_2 0.124107 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 15, LRS -0.010714,LRS_1 0.023214, LRS_2 0.097321 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 16, LRS -0.059821,LRS_1 -0.010714, LRS_2 0.023214 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 17, LRS -0.075000,LRS_1 -0.059821, LRS_2 -0.010714 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 18, LRS -0.107143,LRS_1 -0.075000, LRS_2 -0.059821 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 19, LRS -0.184821,LRS_1 -0.107143, LRS_2 -0.075000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 20, LRS -0.231250,LRS_1 -0.184821, LRS_2 -0.107143 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 21, LRS -0.233929,LRS_1 -0.231250, LRS_2 -0.184821 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 22, LRS -0.196429,LRS_1 -0.233929, LRS_2 -0.231250 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 23, LRS -0.150893,LRS_1 999.500000, LRS_2 -0.233929 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 24, LRS -0.060714,LRS_1 -0.150893, LRS_2 999.500000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 25, LRS -0.192857,LRS_1 1001.000000, LRS_2 -0.150893 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 26, LRS -0.397321,LRS_1 -0.192857, LRS_2 1001.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 27, LRS -0.616071,LRS_1 -0.397321, LRS_2 -0.192857 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 28, LRS -0.805357,LRS_1 -0.616071, LRS_2 -0.397321 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 29, LRS -1.008036,LRS_1 -0.805357, LRS_2 -0.616071 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 30, LRS -1.148214,LRS_1 -1.008036, LRS_2 -0.805357 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 31, LRS -1.267857,LRS_1 -1.148214, LRS_2 -1.008036 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 32, LRS -1.350893,LRS_1 -1.267857, LRS_2 -1.148214 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 33, LRS -1.390179,LRS_1 -1.350893, LRS_2 -1.267857 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 34, LRS -1.400000,LRS_1 -1.390179, LRS_2 -1.350893 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 35, LRS -1.345536,LRS_1 -1.400000, LRS_2 -1.390179 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 36, LRS -1.231250,LRS_1 985.000000, LRS_2 -1.400000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 37, LRS -1.032143,LRS_1 -1.231250, LRS_2 985.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 38, LRS -0.763393,LRS_1 986.000000, LRS_2 -1.231250 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 39, LRS -0.413393,LRS_1 -0.763393, LRS_2 986.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 40, LRS -0.249107,LRS_1 985.250000, LRS_2 -0.763393 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 41, LRS -0.172321,LRS_1 -0.249107, LRS_2 985.250000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 42, LRS -0.152679,LRS_1 985.000000, LRS_2 -0.249107 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 43, LRS -0.120536,LRS_1 -0.152679, LRS_2 985.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 44, LRS -0.097321,LRS_1 984.250000, LRS_2 -0.152679 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 45, LRS -0.098214,LRS_1 -0.097321, LRS_2 984.250000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 46, LRS -0.112500,LRS_1 -0.098214, LRS_2 -0.097321 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 47, LRS -0.150000,LRS_1 -0.112500, LRS_2 -0.098214 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 48, LRS -0.178571,LRS_1 -0.150000, LRS_2 -0.112500 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 49, LRS -0.168750,LRS_1 -0.178571, LRS_2 -0.150000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 50, LRS -0.150893,LRS_1 984.250000, LRS_2 -0.178571 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 51, LRS -0.131250,LRS_1 -0.150893, LRS_2 984.250000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 52, LRS -0.104464,LRS_1 984.000000, LRS_2 -0.150893 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 53, LRS -0.072321,LRS_1 -0.104464, LRS_2 984.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 54, LRS -0.050000,LRS_1 983.750000, LRS_2 -0.104464 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 55, LRS -0.025000,LRS_1 -0.050000, LRS_2 983.750000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 56, LRS -0.004464,LRS_1 984.500000, LRS_2 -0.050000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 57, LRS 0.003571,LRS_1 -0.004464, LRS_2 984.500000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 58, LRS 0.006250,LRS_1 984.500000, LRS_2 -0.004464 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 59, LRS 0.010714,LRS_1 0.006250, LRS_2 984.500000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 60, LRS 0.002679,LRS_1 984.000000, LRS_2 0.006250 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 61, LRS 0.001786,LRS_1 0.002679, LRS_2 984.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 62, LRS 0.000893,LRS_1 0.001786, LRS_2 0.002679 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 63, LRS -0.000000,LRS_1 0.000893, LRS_2 0.001786 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 64, LRS -0.007143,LRS_1 -0.000000, LRS_2 0.000893 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 65, LRS -0.014286,LRS_1 -0.007143, LRS_2 -0.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 66, LRS -0.003571,LRS_1 -0.014286, LRS_2 -0.007143 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 67, LRS 0.010714,LRS_1 984.250000, LRS_2 -0.014286 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 68, LRS 0.048214,LRS_1 0.010714, LRS_2 984.250000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 69, LRS 0.118750,LRS_1 984.750000, LRS_2 0.010714 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 70, LRS 0.148214,LRS_1 0.118750, LRS_2 984.750000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 71, LRS 0.203571,LRS_1 984.000000, LRS_2 0.118750 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 72, LRS 0.249107,LRS_1 0.203571, LRS_2 984.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 73, LRS 0.314286,LRS_1 987.000000, LRS_2 0.203571 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 74, LRS 0.387500,LRS_1 0.314286, LRS_2 987.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 75, LRS 0.421429,LRS_1 989.000000, LRS_2 0.314286 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 76, LRS 0.412500,LRS_1 0.421429, LRS_2 989.000000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 77, LRS 0.390179,LRS_1 0.412500, LRS_2 0.421429 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 78, LRS 0.379464,LRS_1 0.390179, LRS_2 0.412500 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 79, LRS 0.325893,LRS_1 0.379464, LRS_2 0.390179 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 80, LRS 0.276786,LRS_1 0.325893, LRS_2 0.379464 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 81, LRS 0.258036,LRS_1 0.276786, LRS_2 0.325893 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 82, LRS 0.203571,LRS_1 0.258036, LRS_2 0.276786 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 83, LRS 0.150000,LRS_1 0.203571, LRS_2 0.258036 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 84, LRS 0.116071,LRS_1 0.150000, LRS_2 0.203571 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 85, LRS 0.036607,LRS_1 0.116071, LRS_2 0.150000 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 86, LRS -0.020536,LRS_1 0.036607, LRS_2 0.116071 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 87, LRS -0.085714,LRS_1 -0.020536, LRS_2 0.036607 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 88, LRS -0.114286,LRS_1 -0.085714, LRS_2 -0.020536 | 2017-11-10 16:13:48 *
Chart: ZS-201801-ECBOT 15 Min #1 | Study: Kubera_mod_TDEMA | index 89, LRS -0.108036,LRS_1 -0.114286, LRS_2 -0.085714 | 2017-11-10 16:13:48 *
[2017-11-10 22:29:48]
bala - Posts: 74
Hi,

In the above log please read LRS as LRS[sc.Index], LRS_1 as LRS[sc.Index-1], LRS_2 as [sc.Index-2].

If I am incorrect and I cannot use the values of LRS[sc.Index-1] or LRS[sc.Index-2] please let me know.
[2017-11-11 22:16:56]
bala - Posts: 74
Please ignore the help request. I was able to solve the problem by defining an array to store the values of LRS.

Thanks

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account