I need someone to add mathematical calculations to my existing python script

Job ID: 30755152

Budget: $30 – $250 AUD

I currently have a python script that calculates realised gains and losses for directors and updates this onto an excel sheet. I have updated the python script and also the output file from the script.

I require some updates to the python script:
• Add column: Amount of stocks a particular director is invested in.*
• Add column: Amount of directors who have invested in a particular stock.*
• Formatting: Fix underlying data to display dollar signs, commas and rounding where appropriate.*
• Add Column: Can we create a column in the underlying data that tells us how many days since the last purchase of the stock. Up to you whether you want this to be how many days since any director purchased or a specific director. Very clunky to do in PBI.
• Add Column: Let's make a column marking 'on-market transactions' as '1' and off-market as '2'. This makes it so much easier to do some of the other things we talked about today.
• Add Column: Number of on market trades in the last year. Again up to you if you'd like to do this by stock or by director.

Additional:
• Add column: 'Stock code' + 'Director' + 'Amount (Value of gain)' sorted in descending order by 'Amount'.
• Add column: Largest value transaction (top 20) only for the week preceding the latest refresh of the data. i.e. this should only ever be 20 rows, not for the entire dataset.
• Add column: Same as above but for volume instead.
Add column: All directors that have bought value on market above their historical average sorted in descending order by Standard deviation from their mean average weekly purchase.
Related categories: Python Excel Mathematics Software Development Coding