def setShares(self,shares):
        
        if len(shares) != self.histPrice.shape[1]:
            raise AttributeError('Wrong size of shares vector.')
        self.params['shares'] = shares
        self.params['capital'] = self.params['shares']*self.params['last']
set number of shares, adjust capital
dataset/ETHPy150Open cmorgan/trading-with-python/lib/classes.py/Portfolio.setShares