docs: def to_df(self, condition=True, entities=True, timing=True, sampling_rate=None):
          '''Convert to a DataFrame, with columns for name and entities.
  
          Parameters
          ----------
          condition : :obj:`bool`
              If True, adds a column for condition name, and names the amplitude
              column 'amplitude'. If False, returns just onset, duration, and
              amplitude, and gives the amplitude column the current column name.
          entities : :obj:`bool`
              If True, adds extra columns for all entities.
          timing : :obj:`bool`
              If True, includes onset and duration columns (even though events are
              sampled uniformly). If False, omits them.
          '''
          if sampling_rate not in (None, self.sampling_rate):
              return self.resample(sampling_rate).to_df(condition, entities)
  
          df = super(DenseRunVariable, self).to_df(condition, entities)
  
          if timing:
              df['onset'] = self.timestamps.values.astype(float) / 1e+9
              df['duration'] = 1. / self.sampling_rate
  
          return df