TC2000.com• Download software • Tutorial videos • Subscription & data-feed pricing • Class schedule
TC2000Brokerage.com• New account application • Trading resources • Margin rates • Stock & option commissions
Worden Discussion Forum
Don't leave it running unattended.
Wow! You did it again, Bruce. Like Al G. Ive had too much coffee and sent the request twice.
So for both StockGuy and Bruce thanks!
Hi. I've enjoyed coding in PSF and the discussion on this website for several years now. It's a great addition to my stock trading. I've looked at Heikin-Ashi recently and naturally have the question: "Can we program using the Heikin model in PCF?". I am asking this question but DO NOT WANT TO ROCK ANY BOATS!
VALUE Heikin-Ashi Definition
Close = (Open+High+Low+Close)/4
Open = (Open (previous bar) + Close (previous bar))/2
High = Max (High, Open or Close)
Low = Min (Low, Open or Close)
These definitions would put into question the PCF values of C, H, L, O.
I got it. Thanks HarleyBD
Hello Bruce, could I also have a copy of the TTM SQUEEZE INDICATOR via TCMail?
Thanks for the reply and I'm sorry for the BAD code. Here is an example of the code I'm talking about with using nested IIF statements: (CAM Indicator)
IIF(ADX10.10>=ADX10.10.1 AND MACD12.26>MACD12.26.1,4, IIF(ADX10.10<=ADX10.10.1 AND MACD12.26<MACD12.26.1,3, IIF(ADX10.10>=ADX10.10.1 AND MACD12.26<MACD12.26.1,2, IIF(ADX10.10<=ADX10.10.1 AND MACD12.26>MACD12.26.1,1,0))))
is it faster than this (yes I know that the results can not be the same, but the commands are similar; just in theory)
IIF(ADX10.10<=ADX10.10.1 AND MACD12.26<MACD12.26.1,3,0)the
IIF(ADX10.10>=ADX10.10.1 AND MACD12.26>MACD12.26.1,4,0)
IIF(ADX10.10>=ADX10.10.1 AND MACD12.26<MACD12.26.1,2, 0)
IIF(ADX10.10<=ADX10.10.1 AND MACD12.26>MACD12.26.1,1,0)
When I test the nested IIF code in edit mode, all commands are executed. Whether they all are executed during realtime running is the question.
Hi, I have a general programming question. How can we write quick code?
One sure way is to use fewer commands! I'm clear about the code: (a*b + a*c) is better written a*(b+c). There is one less command.
What about nested IIF() statements? Is this code: IIF(a,1,IIF(b,2,IIF(c,3,0) faster that it's equivalent:
IIF(a,1,0) IIF(b,2,0) IIF(c,3,0)
Just wondering, because I'm scanning all stocks during cribbage.
Hi, Could I have a copy of Bruce's TCMail with chart?
Could I possibly get a copy of your TTM Squeeze indicator for V17 ?
Thanks in advance.