The oscillation of a Laplacian eigenfunction gives a great deal of information about the manifold on which it is defined. This oscillation can be encoded in the nodal deficiency, an important geometric quantity that is notoriously hard to compute, or even estimate. Here we compare two recently obtained formulas for the nodal deficiency, one in terms of an energy function on the space of equipartitions of the manifold, and the other in terms of a two-sided Dirichlet-to-Neumann map defined on the nodal set. We relate these two approaches by giving an explicit formula for the Hessian of the equipartition energy in terms of the Dirichlet-to-Neumann map. This allows us to compute Hessian eigenfunctions, and hence directions of steepest descent, for the equipartition energy in terms of the corresponding Dirichlet-to-Neumann eigenfunctions. Our results do not assume bipartiteness, and hence are relevant to the study of spectral minimal partitions.