INNER CODE UNIT · Python
copy_from
baileydanseglio/thetadata-python · thetadata/client.py:143
def copy_from(self, other_ohlcvc):
self.ms_of_day = other_ohlcvc.ms_of_day
self.open = other_ohlcvc.open
self.high = other_ohlcvc.high
self.low = other_ohlcvc.low
self.close = other_ohlcvc.close
self.volume = other_ohlcvc.volume
self.count = other_ohlcvc.count
self.date = other_ohlcvc.date
def to_string(self) -> str:
"""String representation of a trade."""
return 'ms_of_day: ' + str(self.ms_of_day) + ' open: ' + str(self.open) + ' high: ' + str(self.high) + \
' low: ' + str(self.low) + ' close: ' + str(self.close) + ' volume: ' + str(self.volume) +\
' count: ' + str(self.count) + ' date: ' + str(self.date)
class Quote: