Didn't want you to think I forgot you. Just had to do some
other duties until now.
I see that both Ara and Anthony have answered you, and what Anthony coded
will work for your needs, I believe. One possible caveat about the
additional indicators you add, you might want to also open and close them with
TimeFrameSet(in Daily) and TimeFrameRestore(). I haven't tried to code
this out, but I have a recollection that when I once did something like what you
are doing, it made a difference.
Also be sensitive if your additional daily indicators have a
ParamField to select to what the added code is applied. If it defaults
to -1 it will be working on the weekly data from your candles.
The fix is to modify the additional code to remove the ParamField and
replace it with C or else always ensure the parameters are set to Close,
not weekly.
----- Original Message -----
Sent: Thursday, March 04, 2010 3:37
PM
Subject: [amibroker] Re: Is it possible
to display a daily indicator on a weekly chart ???
Hello Patrick,
Thanks for the response. Yes, this is exactly the opporsite to
what the Ami help describe
(ie weekly on daily chart ) - what I need is daily on weekly chart.
I checked everywhere including manual, user grop etc and tried various
combinations of TimeFrame functions in AFL with no luck.
Any help would be greatly appreciated.
--- In amibroker@xxxxxxxxxxxxxxx, "NW Trader" <ta4charts@xxx>
wrote:
>
> Hi Ice,
>
> Apologies, didn't read your
whole message. I'll try to get back to you later after the market.
>
> Peace and Justice --- Patrick
> ----- Original Message -----
> From: NW Trader
> To: amibroker@xxxxxxxxxxxxxxx
> Sent:
Thursday, March 04, 2010 9:51 AM
> Subject: Re: [amibroker] Is it
possible to display a daily indicator on a weekly chart ???
>
>
>
>
>
> Hi ice,
>
> Yes it is. See
TimeFrameSet() and TimeFrameRestore() in the AFL help. Hint, look at how one
plots daily info on intraday charts.
>
> Peace and Justice ---
Patrick
> ----- Original Message -----
> From: iceboundbug
> To: amibroker@xxxxxxxxxxxxxxx
> Sent: Thursday, March 04, 2010
5:41 AM
> Subject: [amibroker] Is it possible to display a daily
indicator on a weekly chart ???
>
>
> Hi all,
>
> I tried to display a daily indicator on a weekly chart without any
success. I would appreciate if someone can show me how.
>
>
Thanks in advance.
>
>
>
> My attempt is listed
below.
>
>
>
> /*Intent is to display daily
indicator on a weekly chart*/
>
>
//////////////////////////////////////////////////
>
>
TimeFrameSet( inDaily);
>
> DailyGSPCClose = Foreign( "^GSPC",
"C" ) ;
>
> CrossBellow = IIf(MA(DailyGSPCClose ,10) <
MA(DailyGSPCClose ,30) , 1 , 0 ) ;
>
> //Plot(CrossBellow ,"
",IIf(CrossBellow == 0, colorDarkGreen,
colorRed),styleOwnScale|styleArea|styleNoLabel,-200,15);
>
>
StaticVarSet("BMD", CrossBellow);
>
> TimeFrameRestore();
>
>
/////////////////////////////////////////////////////
>
>
/////////////////////////////////////////////////////
>
>
TimeFrameSet( inDaily);
>
> temp = StaticVarGet("BMD");
>
> BMW = TimeFrameCompress( temp , inWeekly );
>
>
StaticVarSet("BMDonW", BMW );
>
> TimeFrameRestore();
>
> /////////////////////////////////////////////////////
>
> /////////////////////////////////////////////////////
>
> TimeFrameSet( inWeekly);
>
> temp1 =
StaticVarGet("BMDonW");
>
> Plot(temp1 ," ",IIf(temp1 == 0,
colorDarkGreen,
colorRed),styleOwnScale|styleArea|styleNoLabel,-200,15);
>