class_docstr: Create a HeatMapWithTime layer
  
  Parameters
  ----------
  data: list of list of points of the form [lat, lng] or [lat, lng, weight]
      The points you want to plot. The outer list corresponds to the various time
      steps in sequential order. (weight is in (0, 1] range and defaults to 1 if
      not specified for a point)
  index: Index giving the label (or timestamp) of the elements of data. Should have
      the same length as data, or is replaced by a simple count if not specified.
  name : string, default None
      The name of the Layer, as it will appear in LayerControls.
  radius: default 15.
      The radius used around points for the heatmap.
  blur: default 0.8.
      Blur strength used for the heatmap. Must be between 0 and 1.
  min_opacity: default 0
      The minimum opacity for the heatmap.
  max_opacity: default 0.6
      The maximum opacity for the heatmap.
  scale_radius: default False
      Scale the radius of the points based on the zoom level.
  gradient: dict, default None
      Match point density values to colors. Color can be a name ('red'),
      RGB values ('rgb(255,0,0)') or a hex number ('#FF0000').
  use_local_extrema: default False
      Defines whether the heatmap uses a global extrema set found from the input data
      OR a local extrema (the maximum and minimum of the currently displayed view).
  auto_play: default False
      Automatically play the animation across time.
  display_index: default True
      Display the index (usually time) in the time control.
  index_steps: default 1
      Steps to take in the index dimension between animation steps.
  min_speed: default 0.1
      Minimum fps speed for animation.
  max_speed: default 10
      Maximum fps speed for animation.
  speed_step: default 0.1
      Step between different fps speeds on the speed slider.
  position: default 'bottomleft'
      Position string for the time slider. Format: 'bottom/top'+'left/right'.
  overlay : bool, default True
      Adds the layer as an optional overlay (True) or the base layer (False).
  control : bool, default True
      Whether the Layer will be included in LayerControls.
  show: bool, default True
      Whether the layer will be shown on opening.
class_docstr_tok: ["Create","a","HeatMapWithTime","layer","Parameters","--","--","--","--","--","data",":","list","of","list","of","points","of","the","form","[","lat",",","lng","]","or","[","lat",",","lng",",","weight","]","The","points","you","want","to","plot",".","The","outer","list","corresponds","to","the","various","time","steps","in","sequential","order",".","(","weight","is","in","(","0",",","1","]","range","and","defaults","to","1","if","not","specified","for","a","point",")","index",":","Index","giving","the","label","(","or","timestamp",")","of","the","elements","of","data",".","Should","have","the","same","length","as","data",",","or","is","replaced","by","a","simple","count","if","not","specified",".","name",":","string",",","default","None","The","name","of","the","Layer",",","as","it","will","appear","in","LayerControls",".","radius",":","default","15",".","The","radius","used","around","points","for","the","heatmap",".","blur",":","default","0.8",".","Blur","strength","used","for","the","heatmap",".","Must","be","between","0","and","1.","min_opacity",":","default","0","The","minimum","opacity","for","the","heatmap",".","max_opacity",":","default","0.6","The","maximum","opacity","for","the","heatmap",".","scale_radius",":","default","False","Scale","the","radius","of","the","points","based","on","the","zoom","level",".","gradient",":","dict",",","default","None","Match","point","density","values","to","colors",".","Color","can","be","a","name","(","'red","'",")",",","RGB","values","(","'rgb","(","255,0,0",")","'",")","or","a","hex","number","(","'","#","FF0000","'",")",".","use_local_extrema",":","default","False","Defines","whether","the","heatmap","uses","a","global","extrema","set","found","from","the","input","data","OR","a","local","extrema","(","the","maximum","and","minimum","of","the","currently","displayed","view",")",".","auto_play",":","default","False","Automatically","play","the","animation","across","time",".","display_index",":","default","True","Display","the","index","(","usually","time",")","in","the","time","control",".","index_steps",":","default","1","Steps","to","take","in","the","index","dimension","between","animation","steps",".","min_speed",":","default","0.1","Minimum","fps","speed","for","animation",".","max_speed",":","default","10","Maximum","fps","speed","for","animation",".","speed_step",":","default","0.1","Step","between","different","fps","speeds","on","the","speed","slider",".","position",":","default","'bottomleft'","Position","string","for","the","time","slider",".","Format",":","'bottom\/top'+'left\/right","'",".","overlay",":","bool",",","default","True","Adds","the","layer","as","an","optional","overlay","(","True",")","or","the","base","layer","(","False",")",".","control",":","bool",",","default","True","Whether","the","Layer","will","be","included","in","LayerControls",".","show",":","bool",",","default","True","Whether","the","layer","will","be","shown","on","opening","."]
code: def __init__(
      self,
      data,
      index=None,
      name=None,
      radius=15,
      blur=0.8,
      min_opacity=0,
      max_opacity=0.6,
      scale_radius=False,
      gradient=None,
      use_local_extrema=False,
      auto_play=False,
      display_index=True,
      index_steps=1,
      min_speed=0.1,
      max_speed=10,
      speed_step=0.1,
      position="bottomleft",
      overlay=True,
      control=True,
      show=True,
  ):
      super().__init__(
          name=name, overlay=overlay, control=control, show=show
      )
      self._name = "HeatMap"
      self._control_name = self.get_name() + "Control"
  
      # Input data.
      self.data = data
      self.index = (
          index
          if index is not None
          else [str(i) for i in range(1, len(data) + 1)]
      )
      if len(self.data) != len(self.index):
          raise ValueError(
              "Input data and index are not of compatible lengths."
          )  # noqa
      self.times = list(range(1, len(data) + 1))
  
      # Heatmap settings.
      self.radius = radius
      self.blur = blur
      self.min_opacity = min_opacity
      self.max_opacity = max_opacity
      self.scale_radius = "true" if scale_radius else "false"
      self.use_local_extrema = "true" if use_local_extrema else "false"
      self.gradient = gradient
  
      # Time dimension settings.
      self.auto_play = "true" if auto_play else "false"
      self.display_index = "true" if display_index else "false"
      self.min_speed = min_speed
      self.max_speed = max_speed
      self.position = position
      self.speed_step = speed_step
      self.index_steps = index_steps
  
      # Hard coded defaults for simplicity.
      self.backward_button = "true"
      self.forward_button = "true"
      self.limit_sliders = "true"
      self.limit_minimum_range = 5
      self.loop_button = "true"
      self.speed_slider = "true"
      self.time_slider = "true"
      self.play_button = "true"
      self.play_reverse_button = "true"
      self.time_slider_drap_update = "false"
      self.style_NS = "leaflet-control-timecontrol"
  
file_path: folium/folium/plugins/heat_map_withtime.py
imports: from branca.element import Element, Figure
  from jinja2 import Template
  from folium.elements import JSCSSMixin
  from folium.map import Layer
  from folium.utilities import none_max, none_min
label_desc: Use image node_id 1 to create a new HeatMapWithTime object from inherited base classes: JSCSSMixin, Layer with example: obj = HeatMapWithTime(data, index, name, radius, blur, min_opacity, max_opacity, scale_radius, gradient, use_local_extrema, auto_play, display_index, index_steps, min_speed, max_speed, speed_step, position, overlay, control, show)