code: def tema(close, length=None, talib=None, offset=None, **kwargs):
      """Indicator: Triple Exponential Moving Average (TEMA)"""
      # Validate Arguments
      length = int(length) if length and length > 0 else 10
      close = verify_series(close, length)
      offset = get_offset(offset)
      mode_tal = bool(talib) if isinstance(talib, bool) else True
  
      if close is None:
          return
  
      # Calculate Result
      if Imports["talib"] and mode_tal:
          from talib import TEMA
  
          tema = TEMA(close, length)
      else:
          ema1 = ema(close=close, length=length, **kwargs)
          ema2 = ema(close=ema1, length=length, **kwargs)
          ema3 = ema(close=ema2, length=length, **kwargs)
          tema = 3 * (ema1 - ema2) + ema3
  
      # Offset
      if offset != 0:
          tema = tema.shift(offset)
  
      # Handle fills
      if "fillna" in kwargs:
          tema.fillna(kwargs["fillna"], inplace=True)
      if "fill_method" in kwargs:
          tema.fillna(method=kwargs["fill_method"], inplace=True)
  
      # Name & Category
      tema.name = f"TEMA_{length}"
      tema.category = "overlap"
  
      return tema
  
label_desc: Use image node_id 1 for calling a global function with example usage: tema(close, length, talib, offset) and returns: tema