[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Weekday Profiles



PureBytes Links

Trading Reference Links

I copied the indicator in to TS2000 and it verified. But, it doesn't print.
Seems that the print statements might have changed. any ideas anyone?

Jim Bronke
Phoenix, AZ



----- Original Message -----
From: "Gary Fritz" <fritz@xxxxxxxx>
To: "Prosper" <brente@xxxxxxxxxxxx>; "Omega List" <omega-list@xxxxxxxxxx>
Sent: Monday, May 14, 2001 8:35 AM
Subject: Re: Weekday Profiles


> > Thanks for your reply. No they were visual charts.
>
> Hm, OK.  In any case, another list member had kept a copy of the
> indicator I posted, and sent it back to me.  If anyone is interested,
> here it is.
>
> The indicator doesn't plot anything on the chart.  Instead it prints
> to the Print Log (or whatever "prints" go to in TS2k).  Apply it to a
> daily chart and it summarizes the average and total movement for each
> day of the week.
>
> It summarizes its results at the end of each year, since the market
> changes over time.  In fact my helpful friend noted:  "Monday in the
> spoos has changed from a +5.8% less than a year ago to -0.7% now (it
> went: +5.8, +3.6, +3.9, +1.5, -0.7 , taking readings every few
> months)."  This is the main reason why I don't use it; it changes all
> the time so I can't make use of it in my style of trading.
>
> The indicator prints out results like this:
>
> For year 2000:
>      (Total gain in period = -38.85%)
>         Monday  Tuesday  Wednesday  Thursday  Friday     ALL
>   Avg: -0.477%  -0.524%    -0.763%    0.306% -0.188% -0.329%
>   Tot:  -20.1%   -23.5%     -32.8%     16.8%   -9.1%  -56.4%  (252
> days)
>
> For chart period ending 1010509:
>      (Total gain in period = -17.60%)
>         Monday  Tuesday  Wednesday  Thursday  Friday     ALL
>   Avg: -0.337%  -1.069%     1.026%    0.593% -1.095% -0.176%
>   Tot:   -5.3%   -18.5%      20.2%     11.2%  -17.1%  -14.4%  ( 88 days)
>
> (View this with a fixed-pitch font like Courier New for best results.)
>
> Each weekday's results are listed separately, as well as the total
> results for "ALL" weekdays.  The "Avg" is the average movement per
> day, i.e. on average the market dropped 0.477% on every Monday in
> 2000.  The "Tot" row shows the TOTAL movement for that day during the
> entire year.  So the market dropped 20.1% on ALL Mondays put
> together.  There were 47 Mondays on the chart that year, and
>   (1-0.004763)^47 = (1-0.201).
>
> I didn't explicitly calculate the overnight vs. daily moves.  However
> notice the gain for the entire period is not the same as the gain for
> "ALL" days; that's because the "ALL" column shows the RTH-only
> movement for M-F.  The difference between the "ALL" "Tot:" field and
> the "Total gain in period" is the result of overnight action.  So if
> you had been long from 1/1/00 to 12/31/00, you would have lost
> 38.85%.  But if you had gone long at the open every morning, and
> exited at the close every afternoon, you'd have lost 56.4%.
>
> This indicator works only on daily data.  If you wanted, you could
> modify it to place the data into intraday buckets, instead of daily
> buckets.  This would allow you to see e.g. how much the market
> generally moves during the first hour vs. the second hour.
>
> Gary
>
>
> { DayOfWeek %gain indicator
>   Calculate the daily gain (from open to close) for each market day,
>   and display results for individual weekdays.
>
>   v1.01
>   Gary Fritz
>   5/14/2001
> }
>
> vars:  dday(0), totpct(0), totdays(0), YearOpen(Open);
> arrays:  daypct[5](1), count[5](0);
>
> { Report yearly figures when we hit a new year }
>
> if (Year(Date) <> Year(Date[1])) OR LastBarOnChart then begin
>   if LastBarOnChart
>     then print("For chart period ending ",Date:6:0,":")
>     else print("For year ",1900+Year(Date[1]):4:0,":");
>   if YearOpen <> 0 then print("    (Total gain in period =
",100*Close[1]/YearOpen-100:3:2,"%)");
>
>   { Calculate total of all weekday returns }
>
>   totpct = 1;
>   totdays = 0;
>   for dday = 1 to 5 begin
>     totpct = totpct * daypct[dday];
>     totdays = totdays + count[dday];
>     end;
>
>   print("       Monday  Tuesday  Wednesday  Thursday  Friday     ALL");
>   print(" Avg: ",100*power(daypct[1],1/count[1])-100:2:3,"%  ",
>              100*power(daypct[2],1/count[2])-100:2:3,"%    ",
>              100*power(daypct[3],1/count[3])-100:2:3,"%   ",
>              100*power(daypct[4],1/count[4])-100:2:3,"% ",
>              100*power(daypct[5],1/count[5])-100:2:3,"% ",
>              100*power(totpct,   1/totdays )-100:2:3,"%");
>   print(" Tot:  ",100*daypct[1]-100:3:1,"%   ",
>              100*daypct[2]-100:3:1,"%     ",
>              100*daypct[3]-100:3:1,"%    ",
>              100*daypct[4]-100:3:1,"%  ",
>              100*daypct[5]-100:3:1,"%  ",
>              100*totpct-100:3:1,"%  (",totdays:3:0," days)");
>   print;
>
>   { Re-init for new year }
>
>   for dday = 1 to 5 begin
>     daypct[dday] = 1;
>     count[dday] = 0;
>     end;
>   YearOpen = Open;
>   end;
>
> dday = DayOfWeek(Date);
>
> { Calculate today's return, and multiply it into the running total
>   for that weekday }
>
> daypct[dday] = daypct[dday] * (1 + (Close - Open)/Open);
> count[dday] = count[dday] + 1;
>
> if false then plot1(0,"");
>