code: def from_dict(data, ctx):
          
  
          data = data.copy()
  
          if data.get('o') is not None:
              data['o'] = ctx.convert_decimal_number(
                  data.get('o')
              )
  
          if data.get('h') is not None:
              data['h'] = ctx.convert_decimal_number(
                  data.get('h')
              )
  
          if data.get('l') is not None:
              data['l'] = ctx.convert_decimal_number(
                  data.get('l')
              )
  
          if data.get('c') is not None:
              data['c'] = ctx.convert_decimal_number(
                  data.get('c')
              )
  
          return CandlestickData(**data)
docs: Instantiate a new CandlestickData from a dict (generally from loading a
          JSON response). The data used to instantiate the CandlestickData is a
          shallow copy of the dict passed in, with any complex child types
          instantiated appropriately.