Skip to content

Commit

Permalink
updated read_mallet_word_weights()
Browse files Browse the repository at this point in the history
  • Loading branch information
sina.bock@stud-mail.uni-wuerzburg.de committed Jun 7, 2017
1 parent ea3d81c commit 8b2c774
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dariah_topics/visualization.py
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ def get_topicRank(topic, topicRanksFile):
def read_mallet_word_weights(word_weights_file):
"""Reads Mallet output (topics with words and word weights) into dataframe."""
word_scores = pd.read_table(word_weights_file, header=None, sep="\t")
word_scores = word_scores.sort(columns=[0,2], axis=0, ascending=[True, False])
word_scores = word_scores.sort_values(columns=[0,2], axis=0, ascending=[True, False])
word_scores_grouped = word_scores.groupby(0)
return word_scores_grouped

Expand Down

0 comments on commit 8b2c774

Please sign in to comment.