+ Reply to Thread
Results 1 to 2 of 2

frequency of events

  1. #1
    Registered User
    Join Date
    10-19-2005
    Posts
    1

    frequency of events

    I have a data set that inlcudes date, open and close.

    I'm trying to figure out what percentage of the time something happens. Like, what percentage of the time were the last 3 closes higher and the following open was higher than the last close. So something like what percentage of time is CLOSE3>CLOSE2>CLOSE1(the last 3 closes must be higher than the previous after each day) and OPEN1> than CLOSE3
    Example of data:

    DATE OPEN CLOSE (My notes)
    19820421, 116.350, 117.450 Close 1
    19820422, 117.000, 117.900 Close 2
    19820423, 118.350, 119.650 Close 3
    19820426, 119.300, OPEN1

    Any help would be appreciated.
    Rok

  2. #2
    Dennis Saunders
    Guest

    Re: frequency of events

    Not elegant but it works for me. Enter this formula in D5 and copy down to
    D371 (for a year's trading?)

    =IF(B5="","",IF(AND(B5>C4,C4>C3,C3>C2),1,0))

    In D1 enter

    =SUM(D5:D371)/COUNTA(D5:D371) and format as %age.
    You'll have to adjust it 'cos of your notes (in col D) and it's my bowling
    night
    Regards Radar



+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1