All,
I have the following information in a csv file
Starting Position = 300
Date,Symbol,Description,T_Qty,Position
02-Jan-04,A,4000
05-Jan-04,A,-600
06-Jan-04,A,-900
I have this data for 1000s of securities for the whole of last year. I have to compute the position for all the rows.
For the first day it would be T_Qty + Starting position and that row would become
02-Jan-04,A,4000,4300
For the subsequent rows, it would be T-Qty + previous Position
05-Jan-04,A,-600,5700
06-Jan-04,A,-900,4800
I have only one security listed above. I have thousnads of securities like this.
My idea is to group by securities, then add up quantities going through line by line. Anyone having better idea and suggest me how to do this?
Thanks
Rama
I have the following information in a csv file
Starting Position = 300
Date,Symbol,Description,T_Qty,Position
02-Jan-04,A,4000
05-Jan-04,A,-600
06-Jan-04,A,-900
I have this data for 1000s of securities for the whole of last year. I have to compute the position for all the rows.
For the first day it would be T_Qty + Starting position and that row would become
02-Jan-04,A,4000,4300
For the subsequent rows, it would be T-Qty + previous Position
05-Jan-04,A,-600,5700
06-Jan-04,A,-900,4800
I have only one security listed above. I have thousnads of securities like this.
My idea is to group by securities, then add up quantities going through line by line. Anyone having better idea and suggest me how to do this?
Thanks
Rama