+ Reply to Thread
Results 1 to 6 of 6

Heads and Tails Macro Separate Column for Head; Separate Column For Tails

  1. #1
    Forum Contributor
    Join Date
    10-25-2012
    Location
    Honolulu, Hawaii
    MS-Off Ver
    Excel 2013
    Posts
    128

    Heads and Tails Macro Separate Column for Head; Separate Column For Tails

    Hello and thank you to all who reads this !

    - I have the following code for a heads or tails macro that counts the consecutive heads or tails in column A then places the answer in Column B.
    - What I need is a column C that only has the consecutive number of times Tails occurred, while column B only has the consecutive number of times Heads occurred

    - The code below places both consecutive numbers in the same column

    Please Login or Register  to view this content.

  2. #2
    Forum Expert Crooza's Avatar
    Join Date
    10-19-2013
    Location
    Hunter Valley, Australia
    MS-Off Ver
    Excel 2003 /7/10
    Posts
    2,082

    Re: Heads and Tails Macro Separate Column for Head; Separate Column For Tails

    Not sure if your column A is populated with "Heads" and "Tails" or "H" and "T" but this will work for either scenario

    Please Login or Register  to view this content.
    Happy with my advice? Click on the * reputation button below

  3. #3
    Forum Contributor
    Join Date
    10-25-2012
    Location
    Honolulu, Hawaii
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Heads and Tails Macro Separate Column for Head; Separate Column For Tails

    Holy Jesus in the morning it works great !!! Thankyou thankyou!

    One last thing: The first row has headers, how do you start the count in row 2

    I have tried several combinations i.e. "A2:A" and I cannot get it to work correctly. It is placing a value in row 1 where it should be blank because the headers are there.

    Aloha

  4. #4
    Forum Expert Crooza's Avatar
    Join Date
    10-19-2013
    Location
    Hunter Valley, Australia
    MS-Off Ver
    Excel 2003 /7/10
    Posts
    2,082

    Re: Heads and Tails Macro Separate Column for Head; Separate Column For Tails

    try changing this line

    i = 1

    to

    i = 2

  5. #5
    Forum Contributor
    Join Date
    10-25-2012
    Location
    Honolulu, Hawaii
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Heads and Tails Macro Separate Column for Head; Separate Column For Tails

    Geez, so simple but complex , I read that somewhere but never applied it . Thankyou very very much !

    Aloha

  6. #6
    Forum Contributor
    Join Date
    10-25-2012
    Location
    Honolulu, Hawaii
    MS-Off Ver
    Excel 2013
    Posts
    128

    Re: Heads and Tails Macro Separate Column for Head; Separate Column For Tails

    Geez, so simple but complex , I read that somewhere but never applied it . Thankyou very very much !

    Aloha

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] What Would The Formula Be For How Many Occurances Of Heads And Tails
    By rmccain in forum Excel Formulas & Functions
    Replies: 21
    Last Post: 10-30-2012, 10:41 PM
  2. Generating a Random Heads or Tails Result Over X Coin Flips
    By COgreywolf in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-19-2012, 04:18 PM
  3. Average Cells (Removing Zeros on Tails)
    By John Bates in forum Excel General
    Replies: 6
    Last Post: 02-21-2012, 11:56 AM
  4. Replies: 1
    Last Post: 01-12-2012, 07:50 PM
  5. Tails of line charts
    By matt4003 in forum Excel Charting & Pivots
    Replies: 7
    Last Post: 07-23-2010, 03:47 PM
  6. In a t-test, what are tails?
    By Dave in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 10-28-2005, 09:05 PM
  7. Define 'tails' and 'type' better than the TTEST help file.
    By goodmonkey in forum Excel General
    Replies: 1
    Last Post: 05-04-2005, 11:06 PM

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