text_html_output_1.png
import networkx as nx

import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)

df = pd.read_csv('../input/aipowered-literature-review-csvs/kaggle/working/TIE/Proportion of patients who were asymptomatic.csv')

df1 = pd.read_csv('../input/aipowered-literature-review-csvs/kaggle/working/TIE/Pediatric patients who were asymptomatic.csv')

df1 = df1.rename(columns={'Unnamed: 0': 'unnamed1', 'Asymptomatic Proportion': 'asymptomatic1', 'Age': 'age'})

df1_age = pd.DataFrame({'Date': df1.Date, 'age': df1.age})

import networkx as nx
df1 = pd.DataFrame(df1['asymptomatic1']).groupby(['asymptomatic1']).size().reset_index()
G = nx.from_pandas_edgelist(df1, 'asymptomatic1', 'asymptomatic1', [0])
colors = []
for node in G:
    if node in df1['asymptomatic1'].unique():
        colors.append('green')
    else:
        colors.append('lightgreen')
nx.draw(nx.from_pandas_edgelist(df1, 'asymptomatic1', 'asymptomatic1', [0]), with_labels=True, node_color=colors)