title: TypeError: "'numpy.float64' object is not callable" when using scipy.stats.bootstrap
body: <p>I would like to apply the statistical bootstrapping method with <code>scipy.stats.bootstrap</code>.</p>
  <p>In my code below, I load two distinct .txt files into Python. Each file contains a single column of numeric values (floats). I would like to calculate the coefficient of variation (CV) for each file and compare if their difference in the CV is statistically significant. That is the reason why I use bootstrapping.</p>
  <p>Here is the full code:</p>
  <pre><code>import numpy as np
  import matplotlib as mpl
  import matplotlib.pyplot as plt
  import scipy as sp
  from scipy import stats
  
  
  # Coefficient of variation
  Core_values = np.loadtxt(f&quot;pathtofile/file1.txt&quot;, comments=None, delimiter=None, converters=None,
  skiprows=0, usecols=0,unpack=False, ndmin=0, encoding=None, max_rows=None, like=None)
  
  Periphery_values = np.loadtxt(f&quot;pathtofile/file2.txt&quot;, comments=None, delimiter=None, converters=None,
  skiprows=0, usecols=0, unpack=False, ndmin=0, encoding=None, max_rows=None, like=None)
  
  Results = sp.stats.bootstrap((Core_values, Periphery_values), sp.stats.variation((Core_values, Periphery_values), axis=None), vectorized=False, paired=True, confidence_level=0.95, n_resamples=20000)
  
  print(Results)
  </code></pre>
  <p>When I only apply the code that calculates the CV of both files as follows:</p>
  <pre><code>Results =  sp.stats.variation((Core_values, Periphery_values), axis=None)
  print(Results)
  </code></pre>
  <p>Python gives me the correct result, i.e., one CV value of the values from both input files. However, when implementing <code>sp.stats.variation((Core_values, Periphery_values), axis=None)</code> into the the code for bootstrapping as shown in the full code, I receive the following error message: <code>TypeError: 'numpy.float64' object is not callable</code></p>
  <p>I therefore assume that my mistake is that I provide both samples (Core_values and Periphery_values) into</p>
  <pre><code>Results = sp.stats.bootstrap((Core_values, Periphery_values), sp.stats.variation...
  </code></pre>
  <p>I cannot figure out what the correct implementation would look like to tell Python that I would like to use both samples for bootstrapping in order to avoid the error message.</p>