MaxBeauchemin
2/6/2019 - 10:40 PM

Pandas Sample Data Manipulation

Pandas is a Python library that allows you to manipulate data in multi-dimensional data structures

import numpy as np
import pandas as pd

objs = [
    {
        'Name': 'Max',
        'Age': 24,
        'Location': 'Austin, TX'
    },
    {
        'Name': 'Drew',
        'Age': 35,
        'Location': 'Green Bay, WI'
    },
    {
        'Name': 'Bob',
        'Age': 55,
        'Location': 'Atlanta, GA'
    }
]

table = pd.DataFrame(objs)

The value of table in this context is the following:

AgeLocationName
24Austin, TXMax
35Green Bay, WIDrew
55Atlanta, GABob