Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

CALENDAR DAYS

Here are the steps I follow to convert “trading day” data to “calendar days.”
I am using the 2007 version of Excel. Other versions should be similar.

Before starting, make a duplicate copy of your price data. That way, if
anything goes wrong, you can start over without any harm except for a little
lost time! Hmm, I know this one by experience! 

(1) What is the range of your “trading day” price data? For my
example, the trading days are from 01/02/1980 thru 5/3/2013
(U.S. date format).
(2) AT THE BOTTOM OF THE COLUMN OF DATES (in this example,
AFTER 5/3/2013), I type “1/2/1980” (to match the first day).
(3) In the cell BENEATH 1/2/1980, I write a formula to add ONE to
1/2/1980… I type in the formula as “=”, “(“up arrow” to choose the
cell above)”, “+”, and “1”, followed by the “Enter” key, which
should complete the formula.
(4) Right click on our formula (it should read 1/2/1980) and select
“copy.”
(5) Then highlight a string of cells beneath it (left button on mouse,
and drag the cursor down the column)… then “right click” and
select “PASTE.” You will now have a string of CALENDAR days.
(6) Extend the new calendar days (by copy and pasting as above) until
you have enough calendar days to cover your ENTIRE data set.
(7) Okay, you now have a column of trading days (with data) followed
by a string of calendar days (without data).
(8) THIS NEXT STEP IS VERY IMPORTANT! We want to convert the
“calendar days” (which are only formulas at this point) to regular
data! Move your cursor to the TOP of the column, and select the
entire column. Right click, select “copy”. Right click again, and
KEEPING THE CURSOR INSIDE THE HIGHLIGHTED COLUMN, select
“paste special.” Check “values” on the displayed menu, and click
the “OK” button.
(9) To KEEP FROM CHANGING these values back to formula form again
(or pasting them elsewhere on the spreadsheet by mistake), go to a
blank cell, right click, select “copy”, and press the “Enter” key. The
dotted line around your column of dates will disappear, and your
data will be safe.
(10) It’s a good idea to “SAVE” your file at this point, in case something
goes wrong…
(11) Okay, now we will remove “duplicate” days. When we delete
duplicate data, Excel deletes the SECOND day! That is why we put
our calendar days at the BOTTOM of the column! (We would
otherwise run the chance of deleting our price data also.) Here are
the steps:
(12) Select the “Data” tab on the Excel toolbar (top of page).
(13) Select the “Remove Duplicates” option. UN-CHECK ALL of the
columns EXCEPT the column with our trading days and calendar
days in it! ONLY the dates column should be checked! (otherwise
you will delete duplicate prices also!)
(14) Once ONLY the Date column is checked, then click on “OK.” You
have just removed duplicate days from the bottom of the column!
(15) Last step… Left-click the cursor on ANY cell in our column of dates.
(We want to sort the date column, so we select a CELL THAT IS IN
THE date column.)
(16) Select the “Home” tab (remember, we went to “Data” to remove
the duplicates)… Select “Sort and Filter” (at the far right in 2007
version). Select “Sort Oldest to Newest.” Your weekends and
holidays are now inserted into your trading days!

Hope the instructions weren’t too difficult to follow. Good trading!

Marty

You might also like