  In this paper, we investigate the Gibbs measures associated with the focusing
nonlinear Schr\"odinger equation with an anharmonic potential. We establish a
dichotomy for normalizability and non-normalizability of the Gibbs measures in
one dimension and higher dimensions with radial data. This extends a recent
result of the third and fourth authors with Robert and Seong (2022), where the
focusing Gibbs measures with a harmonic potential were addressed. Notably, in
the case of a subharmonic potential, we identify a novel critical nonlinearity
(below the usual mass-critical exponent) for which the Gibbs measures exhibit a
phase transition. The primary challenge emerges from the limited understanding
of eigenvalues and eigenfunctions of the Schr\"odinger operator with an
anharmonic potential. We overcome the difficulty by employing techniques
related to a recent work of the first two authors (2022).
