Created
June 3, 2020 01:54
-
-
Save JohnDeJesus22/62a15e6cc9dd285b411553b716b29237 to your computer and use it in GitHub Desktop.
convert text to pandas dataframe
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# initiate dataframe for text data | |
text_data = pd.DataFrame() | |
# Create columns for text data | |
text_data['title'] = [article.title for article in articles] | |
text_data['authors'] = [article.authors for article in articles] | |
text_data['text'] = article_text | |
text_data['links'] = search_results |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment