Registered User Joined: 12/2/2004 Posts: 18
|
I am having trouble writing two PCFs. (1) TSV31 as a % of its 15 DMA. I would like to know when TSV31 upcrosses its 15 DMA. (2) MS as % of its 20 DMA. I would like to know when MS upcrosses its 20 DMA.
|
Worden Trainer
Joined: 10/1/2004 Posts: 18,819
|
Check out these previous topics. I found them by using the search function:
MS crossing 22 day MA
Tsv 31 crosses MA 10
- Craig Here to Help!
|
Registered User Joined: 12/2/2004 Posts: 18
|
Is there a way to express the TSV and MS crossovers as a % (percentage) as opposed to Boolean ?
|
Worden Trainer
Joined: 10/1/2004 Posts: 18,819
|
Sure. Just do everything as a percent of ranges:
MS Today vs 20ma ((MS1 - MIN(MS1,20))/(MAX(MS1,20) - MIN(MS1,20)))/((AVG(MS1,20) - MIN(MS1,20))/(MAX(MS1,20) - MIN(MS1,20)))*100
MS Yest vs 20ma ((MS1.1 - MIN(MS1.1,20))/(MAX(MS1.1,20) - MIN(MS1.1,20)))/((AVG(MS1.1,20) - MIN(MS1.1,20))/(MAX(MS1.1,20) - MIN(MS1.1,20)))*100
Values greater than 100 mean the MS is above the average, values less than 100 mean it is below. Same model works for TSV:
TSV31 Today vs 15ma ((TSV31 - MIN(TSV31,15))/(MAX(TSV31,15) - MIN(TSV31,15)))/((AVG(TSV31,15) - MIN(TSV31,15))/(MAX(TSV31,15) - MIN(TSV31,15)))*100
TSV31 Yest vs 15ma ((TSV31.1 - MIN(TSV31.1,15))/(MAX(TSV31.1,15) - MIN(TSV31.1,15)))/((AVG(TSV31.1,15) - MIN(TSV31.1,15))/(MAX(TSV31.1,15) - MIN(TSV31.1,15)))*100
Each are their own PCF. If you set one to above 100 the other to ranges less than 100 you will find crossovers.
- Craig Here to Help!
|