You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
These metrics have a minimum of zero, but with smoothing, the curves go below zero. Other than plotting histograms, a potential solution is to (1) mirror data to negative side, (2) apply KDE, (3) take the distribution for x>=0 only.
The text was updated successfully, but these errors were encountered:
I don't think this is the solution, actually. See this simple example:
The array x2 has only positive values but applying symmetry before the kernel density estimate completely changes the shape, e.g., the ratio of (when x=2.5) to (when x=0).
messing with xlim is not helping either. the kde/facetgrid extends beyond the given limits.
'''
pos_only : Boolean
affects how output after KDE is displayed, only show x-axis >= 0
'''
if pos_only:
g.set_axis_labels(x_label, "").set(xlim=(0.05, df[x_label].max()))
for ax in g.axes.flat:
#ax.margins(0.05,0.15)
ax.set_xlim(0.05,)
These metrics have a minimum of zero, but with smoothing, the curves go below zero. Other than plotting histograms, a potential solution is to (1) mirror data to negative side, (2) apply KDE, (3) take the distribution for x>=0 only.
The text was updated successfully, but these errors were encountered: