title: passing a function in df.insert
body: <p>I have a data frame say, </p>
  
  <pre><code>A B C
  1 2 3
  4 5 6
  7 8 9 
  </code></pre>
  
  <p>I need to create a data frame with the help of a function like, </p>
  
  <pre><code>Var_name Count Max 
  A        3      7
  B        3      8
  C        3      9
  </code></pre>
  
  <p>What I tried is , </p>
  
  <pre><code>def DQ_Function():
  
      data=load_file_us._get_numeric_data()
      num_cols=data.columns  
      count1=data.count()
  
      df=pd.DataFrame(num_cols,columns=['Var_Name']) # create new dataframe from num_columns  
      df.insert(1,'Count',count1)
      return df
  DQ_Function()
  </code></pre>
  
  <p>But it returns 'NaN' values in the df. Kindly let me know where I am gone wrong. </p>
  
  <p>Thanks in advance.</p>