From: Nate E TeBlunthuis Date: Thu, 12 Nov 2020 19:47:53 +0000 (-0800) Subject: bugfix in completing tfidf similarity matrices. X-Git-Url: https://code.communitydata.science/cdsc_reddit.git/commitdiff_plain/e7942146532ae43d82181d0ed7f60fe60e8dc8b3?ds=sidebyside bugfix in completing tfidf similarity matrices. --- diff --git a/author_cosine_similarity.py b/author_cosine_similarity.py index 7137da4..08001c2 100644 --- a/author_cosine_similarity.py +++ b/author_cosine_similarity.py @@ -71,8 +71,8 @@ https://stanford.edu/~rezab/papers/dimsum.pdf. If similarity_threshold=0 we get similarities = similarities.join(df, on='j') similarities = similarities.rename(columns={'subreddit':"subreddit_j"}) - similarities.write_feather(output_feather) - similarities.write_csv(output_csv) + similarities.to_feather(output_feather) + similarities.to_csv(output_csv) return similarities if __name__ == '__main__': diff --git a/term_cosine_similarity.py b/term_cosine_similarity.py index f4f1c6e..48132a8 100644 --- a/term_cosine_similarity.py +++ b/term_cosine_similarity.py @@ -71,8 +71,8 @@ https://stanford.edu/~rezab/papers/dimsum.pdf. If similarity_threshold=0 we get similarities = similarities.join(df, on='j') similarities = similarities.rename(columns={'subreddit':"subreddit_j"}) - similarities.write_feather(output_feather) - similarities.write_csv(output_csv) + similarities.to_feather(output_feather) + similarities.to_csv(output_csv) return similarities if __name__ == '__main__':