diff --git a/HISTORY.rst b/HISTORY.rst index d55ec558..442314e1 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -3,6 +3,10 @@ History ------- +3.4.1 (2023-04-23) +~~~~~~~~~~~~~~~~~~ +* Pandas 2.x release, the drop shall use .drop(saliency, axis=1) #247 + 3.4.0 (2023-02-12) ~~~~~~~~~~~~~~~~~~ diff --git a/pyLDAvis/_prepare.py b/pyLDAvis/_prepare.py index c3fc45c5..37df65f4 100644 --- a/pyLDAvis/_prepare.py +++ b/pyLDAvis/_prepare.py @@ -241,7 +241,7 @@ def _topic_info(topic_term_dists, topic_proportion, term_frequency, term_topic_f 'Total': term_frequency, 'Category': 'Default'}) default_term_info = default_term_info.sort_values( - by='saliency', ascending=False).head(R).drop('saliency', 1) + by='saliency', ascending=False).head(R).drop('saliency', axis=1) # Rounding Freq and Total to integer values to match LDAvis code: default_term_info['Freq'] = np.floor(default_term_info['Freq']) default_term_info['Total'] = np.floor(default_term_info['Total']) diff --git a/setup.py b/setup.py index f1492282..5ddc92e6 100755 --- a/setup.py +++ b/setup.py @@ -18,7 +18,7 @@ setup( name='pyLDAvis', - version='3.4.0', + version='3.4.1', description='Interactive topic model visualization. Port of the R package.', long_description=readme, author='Ben Mabey',