original_docstring: 
          asigns the categories to each bank_data record based on information
          in categories data
      
docstring: asigns the categories to each bank_data record based on information
  in categories data
docstring_tokens: asigns the categories to each bank_data record based on information in categories data
code: def assign_categories(bank_data, categories):
      '''
          asigns the categories to each bank_data record based on information
          in categories data
      '''
      bank_categories = []
      for i in range(0, len(bank_data)):
          category = "unknown"
          for c in range(0, len(categories)):
              # check for rent
              if "CHECK " in bank_data[i]['description_1']:
                  if bank_data[i]['amount'] == -127.00:
                      category = "rent"
                      break
                  if bank_data[i]['amount'] == -160.00:
                      category = "rent"
                      break
  
              # check categories
              if categories[c][0].lower() in bank_data[i]['description_1'].lower():
                  category = categories[c][1]
                  break
              elif categories[c][0].lower() in bank_data[i]['description_2'].lower():
                  category = categories[c][1]
                  break
              elif categories[c][0].lower() in bank_data[i]['description_3'].lower():
                  category = categories[c][1]
                  break
          bank_categories.append(category)
  
  
      return bank_categories
code_tokens: def assign_categories ( bank_data , categories ) : bank_categories = [ ] for i in range ( 0 , len ( bank_data ) ) : category = "unknown" for c in range ( 0 , len ( categories ) ) : if "CHECK " in bank_data [ i ] [ 'description_1' ] : if bank_data [ i ] [ 'amount' ] == - 127.00 : category = "rent" break if bank_data [ i ] [ 'amount' ] == - 160.00 : category = "rent" break if categories [ c ] [ 0 ] . lower ( ) in bank_data [ i ] [ 'description_1' ] . lower ( ) : category = categories [ c ] [ 1 ] break elif categories [ c ] [ 0 ] . lower ( ) in bank_data [ i ] [ 'description_2' ] . lower ( ) : category = categories [ c ] [ 1 ] break elif categories [ c ] [ 0 ] . lower ( ) in bank_data [ i ] [ 'description_3' ] . lower ( ) : category = categories [ c ] [ 1 ] break bank_categories . append ( category ) return bank_categories
short_docstring: asigns the categories to each bank_data record based on information
  in categories data
short_docstring_tokens: asigns the categories to each bank_data record based on information in categories data
comment: '''
          asigns the categories to each bank_data record based on information
          in categories data
      '''$SEP$# check for rent$SEP$# check categories