def parse_swap_balance(self, response):
    result = {'info': response}
    info = self.safe_value(response, 'info', [])
    for i in range(0, len(info)):
        balance = info[i]
        marketId = self.safe_string(balance, 'instrument_id')
        symbol = marketId
        if (marketId in self.markets_by_id):
            symbol = self.markets_by_id[marketId]['symbol']
        account = self.account()
        account['total'] = self.safe_float(balance, 'equity')
        account['free'] = self.safe_float(balance, 'total_avail_balance')
        result[symbol] = account
    return self.parse_balance(result)
def parse_swap_balance(self, response):
    result = {'info': response}
    info = self.safe_value(response, 'info', [])
    for i in range(0, len(info)):
        balance = info[i]
        marketId = self.safe_string(balance, 'instrument_id')
        symbol = marketId
        if (marketId in self.markets_by_id):
            symbol = self.markets_by_id[marketId]['symbol']
        account = self.account()
        account['total'] = self.safe_float(balance, 'equity')
        account['free'] = self.safe_float(balance, 'total_avail_balance')
        result[symbol] = account
    return self.parse_balance(result)