Hi I have the following data:
stock name month open price close price
A Jan 21.3 22
A Feb 23 21
A March 19 23.5
A Dec 24 26
B Jan 3 3
B Feb 4 5.5
B March 6 8.5
B Dec 11 11.5
How would i get the first value for open price and the last value for close price for each stock using excel vba? For example, stock name A has an open price of 21.3 and a close price of 26 for the full year. The data is already sorted by stock name and month. I have thousands of stock values and need to do it for each one.
Bookmarks