diff --git a/app/Main.hs b/app/Main.hs
--- a/app/Main.hs
+++ b/app/Main.hs
@@ -159,6 +159,8 @@
                         --     . fromMaybe (error "Requires matrix.")
                         --     )
                         --     mat
+                    (DrawItem (DrawProximity gs)) ->
+                        error "Proximity not supported here."
                     _ -> sequence . fmap (loadLabelData delimiter') $ labelsFile'
 
     let readMat file =
diff --git a/birch-beer.cabal b/birch-beer.cabal
--- a/birch-beer.cabal
+++ b/birch-beer.cabal
@@ -1,13 +1,13 @@
 name:                birch-beer
-version:             0.4.1.0
+version:             0.4.2.1
 synopsis:            Plot a colorful tree.
 description:         Generate a tree for displaying a hierarchy of groups with colors, scaling, and more.
 homepage:            http://github.com/GregorySchwartz/birch-beer#readme
 license:             GPL-3
 license-file:        LICENSE
 author:              Gregory W. Schwartz
-maintainer:          gsch@pennmedicine.upenn.edu
-copyright:           2019 Gregory W. Schwartz
+maintainer:          gregory.schwartz@uhnresearch.ca
+copyright:           2022 Gregory W. Schwartz
 category:            Bioinformatics
 build-type:          Simple
 -- extra-source-files:
diff --git a/src/BirchBeer/ColorMap.hs b/src/BirchBeer/ColorMap.hs
--- a/src/BirchBeer/ColorMap.hs
+++ b/src/BirchBeer/ColorMap.hs
@@ -14,6 +14,7 @@
     , getLabelColorMap
     , getLabelCustomColorMap
     , getLabelMapThresholdContinuous
+    , getLabelMapProximity
     , labelToItemColorMap
     , getItemColorMapContinuous
     , getItemValueMap
@@ -43,7 +44,7 @@
 import Data.Foldable (foldl')
 import Data.Function (on)
 import Data.Int (Int32)
-import Data.Maybe (fromMaybe, isNothing)
+import Data.Maybe (fromMaybe, isNothing, mapMaybe)
 import Data.Tuple (swap)
 import Diagrams.Prelude
 import Math.Diversity.Diversity (diversity)
@@ -284,6 +285,39 @@
              . fmap Feature
              . getColNames
              $ mat
+
+-- | Get the spatial neighbor labels of each item, where the label is determined
+-- by the proximity (Euclidean distance) of the items from a collection of nodes.
+getLabelMapProximity
+  :: (TreeItem a)
+  => ClusterGraph a -> CoordinateMap -> ([G.Node], Double) -> LabelMap
+getLabelMapProximity (ClusterGraph gr) (CoordinateMap coordm) (!nodes, !thresh) =
+  LabelMap
+    . Map.fromList
+    . fmap (\ (!x, (!s1, _)) -> (x, assignLabel (s1, x)))
+    . Map.toAscList
+    $ coordm
+  where
+    baseLocations = mapMaybe (flip Map.lookup coordm) . Set.toList $ baseItems
+    baseItems :: Set.Set Id
+    baseItems = Set.fromList
+              . fmap getId
+              . F.toList
+              . mconcat
+              . mapMaybe snd
+              . F.toList
+              . mconcat
+              . fmap (getGraphLeaves gr)
+              $ nodes
+    assignLabel (!s1, !x)
+      | Set.member x baseItems = Label "Base"
+      | any (\(!s2, !v) -> s1 == s2 && v <= thresh)
+          . mapMaybe (\ b
+                     -> Map.lookup x coordm
+                    >>= \z -> Just (fst b, S.norm2 (snd b S.^-^ snd z))
+                     )
+          $ baseLocations = Label "Neighbor"
+      | otherwise = Label "Distant"
 
 -- | Get the colors of each item, where the color is determined by the sum of
 -- features in that item.
diff --git a/src/BirchBeer/Options.hs b/src/BirchBeer/Options.hs
--- a/src/BirchBeer/Options.hs
+++ b/src/BirchBeer/Options.hs
@@ -33,7 +33,7 @@
     , customCut :: [Int] <?> "([Nothing] | NODE) List of nodes to prune (make these nodes leaves). Invoked by --custom-cut 34 --custom-cut 65 etc."
     , rootCut :: Maybe Int <?> "([Nothing] | NODE) Assign a new root to the tree, removing all nodes outside of the subtree."
     , order :: Maybe Double <?> "([1] | DOUBLE) The order of diversity for DrawItem DrawDiversity."
-    , drawLeaf :: Maybe String <?> "([DrawText] | DrawItem DrawItemType) How to draw leaves in the dendrogram. DrawText is the number of items in that leaf. DrawItem is the collection of items represented by circles, consisting of: DrawItem DrawLabel, where each item is colored by its label, DrawItem (DrawContinuous [FEATURE]), where each item is colored by the expression of FEATURE (corresponding to a feature name in the input matrix, [FEATURE] is a list, so if more than one FEATURE is listed, uses the average of the feature values), DrawItem (DrawThresholdContinuous [(FEATURE, THRESHOLD)]), where each item is colored by the binary high / low expression of FEATURE based on THRESHOLD (either `Exact DOUBLE` or `MadMedian DOUBLE`, where Exact just uses the DOUBLE as a cutoff value while MadMedian uses the DOUBLE as the number of MADs away from the median value of the feature) and multiple FEATUREs can be used to combinatorically label items (FEATURE1 high / FEATURE2 low, etc.), DrawItem DrawSumContinuous, where each item is colored by the sum of the post-normalized columns (use --normalization NoneNorm for UMI counts, default), and DrawItem DrawDiversity, where each node is colored by the diversity based on the labels of each item and the color is normalized separately for the leaves and the inner nodes. The default is DrawText, unless --labels-file is provided, in which DrawItem DrawLabel is the default. If the label or feature cannot be found, the default color will be black (check your spelling!)."
+    , drawLeaf :: Maybe String <?> "([DrawText] | DrawItem DrawItemType) How to draw leaves in the dendrogram. DrawText is the number of items in that leaf. DrawItem is the collection of items represented by circles, consisting of: DrawItem DrawLabel, where each item is colored by its label, DrawItem (DrawContinuous [FEATURE]), where each item is colored by the expression of FEATURE (corresponding to a feature name in the input matrix, [FEATURE] is a list, so if more than one FEATURE is listed, uses the average of the feature values), DrawItem (DrawThresholdContinuous [(FEATURE, THRESHOLD)]), where each item is colored by the binary high / low expression of FEATURE based on THRESHOLD (either `Exact DOUBLE` or `MadMedian DOUBLE`, where Exact just uses the DOUBLE as a cutoff value while MadMedian uses the DOUBLE as the number of MADs away from the median value of the feature) and multiple FEATUREs can be used to combinatorically label items (FEATURE1 high / FEATURE2 low, etc.), DrawItem DrawSumContinuous, where each item is colored by the sum of the post-normalized columns (use --normalization NoneNorm for UMI counts, default), DrawItem (DrawProximity ([NODE], DISTANCE)), where each item is colored by its proximity in Euclidean distance to a set of items drawn from a list of NODE, and DrawItem DrawDiversity, where each node is colored by the diversity based on the labels of each item and the color is normalized separately for the leaves and the inner nodes. The default is DrawText, unless --labels-file is provided, in which DrawItem DrawLabel is the default. If the label or feature cannot be found, the default color will be black (check your spelling!)."
     , drawCollection :: Maybe String <?> "([PieChart] | PieRing | IndividualItems | Histogram | NoLeaf | CollectionGraph MAXWEIGHT THRESHOLD [NODE]) How to draw item leaves in the dendrogram. PieRing draws a pie chart ring around the items. PieChart only draws a pie chart instead of items. IndividualItems only draws items, no pie rings or charts. Histogram plots a histogram of the features requested. NoLeaf has no leaf, useful if there are so many items the tree takes very long to render. (CollectionGraph MAXWEIGHT THRESHOLD [NODE]) draws the nodes and edges within leaves that are descendents of NODE (empty list [] indicates draw all leaf networks) based on the input matrix, normalizes edges based on the MAXWEIGHT, and removes edges for display less than THRESHOLD (after normalization, so for CollectionGraph 2 0.5 [26], draw the leaf graphs for all leaves under node 26, then a edge of 0.7 would be removed because (0.7 / 2) < 0.5). For CollectionGraph with no colors, use --draw-leaf \"DrawItem DrawLabel\" and all nodes will be black. If you don't specify this option, DrawText from --draw-leaf overrides this argument and only the number of cells will be plotted."
     , drawMark :: Maybe String <?> "([MarkNone] | MarkModularity | MarkSignificance ) How to draw annotations around each inner node in the tree. MarkNone draws nothing and MarkModularity draws a black circle representing the modularity at that node, darker black means higher modularity for that next split. MarkSignificance is for significance, i.e. p-value, darker means higher value."
     , drawNodeNumber :: Bool <?> "Draw the node numbers on top of each node in the graph."
diff --git a/src/BirchBeer/Types.hs b/src/BirchBeer/Types.hs
--- a/src/BirchBeer/Types.hs
+++ b/src/BirchBeer/Types.hs
@@ -201,6 +201,12 @@
 newtype DiscreteColorMap = DiscreteColorMap
     { unDiscreteColorMap :: [Kolor]
     } deriving (Read, Show)
+newtype Sample = Sample
+    { unSample :: T.Text
+    } deriving (Eq, Ord, Read, Show)
+newtype CoordinateMap = CoordinateMap
+    { unCoordinateMap :: Map.Map Id (Maybe Sample, S.SpVector Double)
+    } deriving (Show)
 newtype L = L Double
 newtype C = C Double
 newtype H = H Double
@@ -216,6 +222,7 @@
     = DrawLabel
     | DrawContinuous [T.Text]
     | DrawThresholdContinuous [(T.Text, Threshold)]
+    | DrawProximity ([G.Node], Double)
     | DrawSumContinuous
     | DrawDiversity
     deriving (Read,Show)
diff --git a/src/BirchBeer/Utility.hs b/src/BirchBeer/Utility.hs
--- a/src/BirchBeer/Utility.hs
+++ b/src/BirchBeer/Utility.hs
@@ -334,7 +334,7 @@
 median :: S.ContParam  -- ^ Parameters /α/ and /β/.
        -> V.Vector Double   -- ^ /x/, the sample data.
        -> Double
-median p = S.continuousBy p 1 2
+median p = S.median p
 
 -- | Get the collection of items in a leaf.
 getGraphLeafItems :: ClusterGraph a -> G.Node -> Seq.Seq a
