Update gmv_portfolio_v_2.R

Updated with some faster functions and standardized code.