Long Lots

Long Lots

Each security is divided into Lots. These do not appear in the user interface, but they are important for calculating gains and returns. Lots, in turn, are composed of transactions. Every time you purchase shares of a stock, a new lot is opened. When you sell shares, they are deducted from the oldest lot that still has shares. (Why the oldest first? We take our cue here from the U.S. tax code) If the oldest lot has shares, but not enough to complete the sale, then the sale may be split into two (or more) transactions, in order to allocate it across multiple lots. If all the lots together do not have enough shares to complete the sale, then the sale is invalid, and an error message is displayed.

This is easiest to explain with examples:

Suppose you buy 100 shares of XYZZ on April 1, 2008, then 100 more shares on April 1, 2009.

Lot 1:
Transaction: 4/1/2008 BUY XYZZ 100

Lot 2:
Transaction: 4/1/2009 BUY XYZZ 100

Each BUY transaction starts its own lot.

Now suppose you sold 50 shares of XYZZ on May 5, 2008. That would be divided up like this:

Lot 1:
Transaction: 4/1/2008 BUY XYZZ 100

Transaction: 5/5/2008 SELL XYZZ 50

Lot 2:
Transaction: 4/1/2009 BUY XYZZ 100

Suppose you also sold 80 shares of XYZZ on September 19, 2009. Since Lot 1 only has 50 shares left, the sale has to be split. In the Transactions tab, you will see your sale of 80 shares, but internally, it is treated like this:

Lot 1:
Transaction: 4/1/2008 BUY XYZZ 100

Transaction: 5/5/2008 SELL XYZZ 50

Transaction: 9/19/2009 SELL XYZZ 50

Lot 2:
Transaction: 4/1/2009 BUY XYZZ 100

Transaction: 9/19/2009 SELL XYZZ 30

At this point, Lot 1 is considered a closed lot, that is, it has no more shares available for sale. Lot 2 still has 70 shares.

Everything we have talked about so far applies to long lots, lots that are created by buying and holding stock. But lots can also be opened by short sale. These short lots behave analogously to long lots, except that every short sale starts a new short lot, and any covering buys will be deducted from the oldest short lot. Short lots will be discussed in more detail later on, so don't worry if you are unfamiliar with the term.

Long Lot Computations

A simple lot (sometimes called a long lot) consists of a stock purchase, possibly followed by stock sales. Each lot maintains three fundamental values that affect all the remaining calculations:

initial quantity: This is the share count of the transaction that opened the lot.

remaining quantity: This is the number of shares that have not been matched with subsequent sell transactions.

initial investment: This is the negative of the cash value of the transaction that opened the lot, because the cash value is the effect on your bank account, but the initial investment is the opposite: it is the value that has been "put into" the stock. So, for example, the cash value of a purchase of 10 shares of XYZZ at $350 is -$3500, and the initial investment is $3500.

From these values, the following investment statistics can be computed for the lot: