""" Risk parity portfolio """


def risk_parity_portfolio(ret):
    init_guess = 1 / ret.std()
    opt_weights = list(init_guess / init_guess.sum())

    return opt_weights

c8e0d19bd9cc1cbf5f29c80d24d4b4a59057261e
<mask token>

<mask token>


def risk_parity_portfolio(ret):
    init_guess = 1 / ret.std()
    opt_weights = list(init_guess / init_guess.sum())
    return opt_weights

""" Risk parity portfolio """


def risk_parity_portfolio(ret):
    init_guess = 1 / ret.std()
    opt_weights = list(init_guess / init_guess.sum())

    return opt_weights
