I am trying to use Timeframegetprice instead of timeframeset and timeframeexpand.
I want to plot a trend ribbon for the next highest time frame.
(In a 5 minute chart I want to plot the ribbon of the 15 minute timeframe and so on.)
The code below does not seem to do what I wish it to do.
What is the code or logic error please?
// set time frame parameters
min1 = Interval()== 60;
min5 = Interval() == 300;
min15 = Interval() == 900;
Hourly = Interval() == 3600;
hour4 = Interval() == 14400;
daily = Interval() == 86401;
week = Interval() == 432001;
// conditional statement to select the next highest time frame (NHTF)
NHTF = IIf( min5,in15Minute, IIf(min15,inHourly, IIf(Hourly,4*inHourly, IIf(Hour4,inDaily, inWeekly))));
// Set NHTF price variable
P = TimeFrameGetPrice("C",NHTF);
Pointers/tips/guidelines appreciated.
Regards
ChrisB
Do you Yahoo!?
Get on board. You're invited to try the new Yahoo! Mail. __._,_.___
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For other support material please check also:
http://www.amibroker.com/support.html
SPONSORED LINKS
| Software support | Small business finance | Business finance online |
| Business finance training | Business finance course |
Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe
__,_._,___
