I understand how to calculate the Annualized return on a stock when I have single purchase ie
(principal + gain/principal) ^ (365/days) - 1
but how is it calculated when I have multiple buys and sells over a time period?
Treat each transaction as separate, with its own principal, its own gain, and its own number of days. Then the total annualized return is just a weighted average of each annualized return, with the weighting related to the number of shares in that transaction.
Since Brad answered with a great reply, I'd like to offer another comment: Be careful with the results. Annualized returns of short term trading can produce some crazy results. For example, a 10% gain in a week isn't unheard of for individual stocks, but (1.1)^52 = 142. or a 14,100% return. This may be obvious, but may help those who aren't so familiar with the numbers to understand that data running less than a year isn't going to provide as much useful conclusion as longer term. Note: Even a year doesn't really reflect success in a given strategy.