From Diminutive Madrill, 4 Months ago, written in Plain Text, viewed 79 times.
URL http://codebin.org/view/31f1f00b Embed
Download Paste or View Raw
  1. for k in range(0, 23566):
  2.     for locality_name in real_estate_spb['locality_name']:
  3.         if 'городской поселок' in locality_name:
  4.             locality_name = locality_name.replace('городской поселок', 'поселок')
  5.         elif 'городской посёлок' in locality_name:
  6.             locality_name = locality_name.replace('городской посёлок', 'поселок')
  7.         elif 'поселок городского типа' in locality_name:
  8.             locality_name = locality_name.replace('поселок городского типа', 'поселок')
  9.         elif 'посёлок городского типа' in locality_name:
  10.             locality_name = locality_name.replace('посёлок городского типа', 'поселок')
  11.         elif 'посёлок' in locality_name:
  12.             locality_name = locality_name.replace('посёлок', 'поселок')
  13.     real_estate_spb.loc[k, 'locality_name'] = locality_name

Replies to Untitled rss

Title Name Language When
Re: Untitled Bistre Coyote python 4 Months ago.

Reply to "Untitled"

Here you can reply to the paste above