In [48]:
xml = ""
with open ("../demos/dataset/nvdcve-2.0-2016_mini.xml") as f:
xml = f.read()
xml;
In [52]:
import xmldataset
# xmldataset declaration
profile = """
nvd
entry.id
"""
# Print the output
print(xmldataset.parse_using_profile(xml, profile))
In [18]:
import pandas as pd
header = pd.read_csv("../demos/dataset/cve_allitems.csv.gz", skiprows=2, nrows=0)
header
Out[18]:
In [36]:
cve = pd.read_csv(
"../demos/dataset/cve_allitems.csv.gz",
skiprows=10,
encoding='latin-1',
names=header
)
cve.head()
Out[36]:
In [39]:
cve.describe(include='all')
Out[39]:
In [41]:
cve.info()
In [ ]:
In [42]:
import xmldataset
# xmldataset declaration
profile = """
colleagues
colleague
title = dataset:colleagues
phone = dataset:colleagues
email = dataset:colleagues"""
# Print the output
print(xmldataset.parse_using_profile(xml, profile))