title: Creating new variable name from existing variable names in Python
body: <p>I have a collection of JSON variables, all with the same format and data irregularities, that I'd like to correct and then reassign to data frames for processing.</p>
  
  <p>Since I'm doing performing the same process over and over, I'm just planning to run cleaning portion of the code as a for loop.  </p>
  
  <p>I'm getting stuck at the point, post-cleaning, that I have a generic dataframe, <em>df</em>, that I now want to assign to a permanent data frame before moving to the next variable. </p>
  
  <p>Ideally, I'd simply call the <code>exec()</code> function, appending the respective variable name to 'df_', but I'm not sure how to strip the variable name as a string from the variable itself, and I also understand this isn't very pythonic.  </p>
  
  <p>I've included the respective code below.  With variable names [a, b, c], I'd like to assign df to a new data frame called df_a, df_b, and df_c respectively.  Any ideas on how to do this.</p>
  
  <pre><code>vars = [a, b, c]
  
  # clean data iteratively
  for i in vars:
      df = pd.DataFrame(i)
      df['value'] = df['value'].replace('.', np.nan).fillna(method='bfill')
      df['value'] = pd.to_numeric(df['value'])
      [???] = df
  </code></pre>
  
  <p>edit: the linked question addresses something different than what I'm asking.  I don't need the variable content, I need the variable name; additionally, I'm asking if there's a more pythonic way to do this...nothing in the linked question addresses this. </p>