Closed MerlinR closed 2 months ago
Example: class Candle: open: float high: float low: float close: float volume: int timestamp: Optional[datetime] = None resolution: Optional[Timeframe] = None _clean_values: Dict[str, float | int] _tag: Optional[str] = None indicators: Dict[str, float | Dict[str, float | None] | None] sub_indicators: Dict[str, float | Dict[str, float | None] | None]
Add a "resolution" attribute to the "Candle" class. Can be used to easily define/see the resolution of single candles. Can re-use the "Timeframe" class as values for the attribute. Can likely auto populate resolution on missing field based on time between given candles as an average. Can also auto populate if Hexital/Indicator is given a timeframe