<jupyter_start><jupyter_text>COVID-19 Literature Publication Times extracted from PubMed<jupyter_code>import pandas
from pubmedpy.esummary import extract_articles_from_esummaries, articles_to_dataframe
litcovid_df = pandas.read_table("data/litcovid.tsv", comment="#")
litcovid_df.head(2)
print(f'{len(litcovid_df):,} articles in litcovid.tsv')
path = "data/litcovid-esummaries.xml.xz"
articles = extract_articles_from_esummaries(path, n_articles=len(litcovid_df))
# show output of a single article
articles[0]
article_df = articles_to_dataframe(articles)
article_df.head(2)
article_df.to_csv("data/litcovid-article-dates.tsv", sep="\t", index=False)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.11634756995581738, 'fraction_numerical': 0.007363770250368188, 'mean_word_length': 9.96774193548387, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 1}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '380132', 'license': 'CC-BY-4.0', 'n_tokens_mistral': 263, 'n_tokens_neox': 243, 'n_words': 39, 'path': '10.extract-litcov-article-info.ipynb', 'repo_name': 'dhimmel/covid-publication-times', 'size': '679'}