Performing Analysis on Green Energy Stock - Columbia University Boot Camp Project
As green energy has become more important nowadays, our clients want to do a guided investment on green energy stocks.
The reach of diversification in this field is great. Mainly because there are many possibilities in how to create energy. Such as: Hydro, bio, wind, geothermal, solar, and others.
By gathering information on 12 companies and their stock prices for a defined period of time (2017 and 2018), it was possible to write a code to go through all stock prices and results to create an annual assessment of the growth of those stocks and its results.
The year 2017 was great for investors who already owned stocks from this portfolio. As shown below:
A starting investment of USD 1,000 in each of these stock in the beginning of 2017 would have cost a total of USD 12,000. The value in the end of 2017 of this portfolio would be USD 20,0078.62. A growth of 40.2%.
As amazing as it sounds, 2018 hit the green energy industry hard.
Where most stocks in the portfolio would have had a loss, however, totalizing USD 17,813.97 (which is still above the initial USD 12k).
This gives an opportunity value to start 2019 with this portfolio as it would be an investment on the dip. All the companies of the portfolio have a solid foundation, so there is a great possibility of a growth in 2019.
It brings the advantage of optimizing the code for efficiency. Sometimes, when writing for the first time, the code may have some long and inefficient paths to run.
The disadvantages might be as macros are more complex, it could be hard to refactor the whole code. Sometimes, gathering the important parts and rewrite may be the best option.
The original one was fixed to the values and less efficient. As in the refactored one, it was simpler written (making it easy to understand).

