<jupyter_start><jupyter_text>Generate a PDF containing a random sample of ICMEs. Plot both the timeseries data and the image representations<jupyter_code>pdf = PdfPages('examining_ICME.pdf')
for i, row in random_sample.iterrows():
    fname, label = row['fname'], row['label']
    fig, df = plot_ts(fname, label)
    fig1, img = plot_img(fname, label, cols=df.columns)
    pdf.savefig(fig)
    pdf.savefig(fig1)
    plt.close(fig)
    plt.close(fig1)
pdf.close()<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.12398373983739837, 'fraction_numerical': 0.006097560975609756, 'mean_word_length': 4.9397590361445785, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, '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': '426843', 'license': 'MIT', 'n_tokens_mistral': 181, 'n_tokens_neox': 180, 'n_words': 42, 'path': 'notebooks/visualizing_chunks.ipynb', 'repo_name': 'nmiles2718/aos_c204_final_project', 'size': '492'}