CrossClj
incanter.core/$map
RECENT
    • ($map fun col-keys)
    • ($map fun col-keys data)
      This function returns a sequence resulting from mapping the given function over
      the value(s) for the given column key(s) of the given dataset.
      Like other '$*' functions, it will use $data as the default dataset
      if none is provided, where $data is set using the with-data macro.
    
      Examples:
    
        (use '(incanter core datasets))
        (def cars (get-dataset :cars))
    
        ($map (fn [s] (/ s)) :speed cars)
        ($map (fn [s d] (/ s d)) [:speed :dist] cars)
    
        (with-data (get-dataset :cars)
          (view ($map (fn [s] (/ s)) :speed))
          (view ($map (fn [s d] (/ s d)) [:speed :dist])))
    
        ;; calculate the speed to dist ratio and append as new column to dataset
        (with-data (get-dataset :cars)
          (conj-cols $data ($map (fn [s d] (/ s d)) [:speed :dist])))
      

    incanter.core/$map found in 1 def, across 1 project.

    Search for vars with similar names in all artifacts: $map

    Search for map in the documentation of all artifacts.

    1 usage in
    incanter-core 1.9.3
    Incanter-core is the core module of the Incanter project.
    Source code