Hi Forum
I have cash flow data for different projects (I included sample data below). Each project has a specific project ID and I attempt to calculate the Internal Rate of Return (IRR) at each point in time, where I have a "Value" entry, assuming the project is acquired at this value ("price" at time 0) and then consider all the future cash in-and outflows after that value timestamp. So in the end, I have a "Timeseries" of IRRs for each of my projects.
I am new to Stata and struggle to implement this. I have already converted the "Value" entries to negative values, reflecting a cash outflow:
I also am aware that there is a finxirr function in Stata. However, I struggle to implement it, as sometimes the dates and project IDs appear more than once, since the cash in-and outflows and the value sometimes are reported at the same point in time and the function requires a timeseries with no double entries per time stamp.
I would highly appreciate your help.
Thanks,
Marion
I have cash flow data for different projects (I included sample data below). Each project has a specific project ID and I attempt to calculate the Internal Rate of Return (IRR) at each point in time, where I have a "Value" entry, assuming the project is acquired at this value ("price" at time 0) and then consider all the future cash in-and outflows after that value timestamp. So in the end, I have a "Timeseries" of IRRs for each of my projects.
I am new to Stata and struggle to implement this. I have already converted the "Value" entries to negative values, reflecting a cash outflow:
Code:
replace Amount = -Amount if Type == "Value"
Code:
Project ID Type Date Amount 1 Value 31/03/06 5150780 1 Outflow 16/05/06 -905304 1 Outflow 16/05/06 1967652 1 Value 30/06/06 3702340 1 Value 30/09/06 4786860 1 Outflow 15/11/06 -53217 1 Distribution 15/11/06 1573913 1 Value 31/12/06 3726690 1 Outflow 14/02/07 -25652 1 Distribution 14/02/07 206261 1 Value 31/03/07 4114080 1 Outflow 16/05/07 -40348 1 Distribution 16/05/07 1531739 1 Value 30/06/07 3236260 1 Value 30/09/07 3109990 1 Value 31/12/07 3233210 1 Outflow 15/02/08 -21478 1 Distribution 15/02/08 347304 1 Value 31/03/08 2968860 1 Outflow 16/05/08 -4870 1 Distribution 16/05/08 699478 1 Value 30/06/08 2436950 1 Outflow 15/08/08 -8696 1 Distribution 15/08/08 635565 1 Value 30/09/08 1525300 1 Distribution 15/11/08 66957 1 Value 31/12/08 840600 1 Outflow 14/02/09 -9826 1 Distribution 14/02/09 50696 1 Value 31/03/09 723730 1 Distribution 16/05/09 87043 1 Value 30/06/09 839390 1 Distribution 15/08/09 401391 1 Value 30/09/09 504340 1 Distribution 15/11/09 113826 1 Value 31/12/09 511910 1 Distribution 14/02/10 48348 1 Value 31/03/10 476950 1 Distribution 16/05/10 256435 1 Value 30/06/10 181730 1 Distribution 15/08/10 140348 1 Value 30/09/10 53470 2 Value 31/03/06 5150780 2 Outflow 16/05/06 -905304 2 Outflow 16/05/06 1967652 2 Value 30/06/06 3702340 2 Value 30/09/06 4786860 2 Outflow 15/11/06 -53217 2 Distribution 15/11/06 1573913 2 Value 31/12/06 3726690 2 Outflow 14/02/07 -25652 2 Distribution 14/02/07 206261 2 Value 31/03/07 4114080 2 Outflow 16/05/07 -40348 2 Distribution 16/05/07 1531739 2 Value 30/06/07 3236260 2 Value 30/09/07 3109990 2 Value 31/12/07 3233210 2 Outflow 15/02/08 -21478 2 Distribution 15/02/08 347304 2 Value 31/03/08 2968860 2 Outflow 16/05/08 -4870 2 Distribution 16/05/08 699478 2 Value 30/06/08 2436950 2 Outflow 15/08/08 -8696 2 Distribution 15/08/08 635565 2 Value 30/09/08 1525300 2 Distribution 15/11/08 66957 2 Value 31/12/08 840600 2 Outflow 14/02/09 -9826 2 Distribution 14/02/09 50696 2 Value 31/03/09 723730 2 Distribution 16/05/09 87043 2 Value 30/06/09 839390 2 Distribution 15/08/09 401391 2 Value 30/09/09 504340 2 Distribution 15/11/09 113826 2 Value 31/12/09 511910 2 Distribution 14/02/10 48348 2 Value 31/03/10 476950 2 Distribution 16/05/10 256435 2 Value 30/06/10 181730 2 Distribution 15/08/10 140348 2 Value 30/09/10 53470
Thanks,
Marion