From 9e383497c06def312f992381db618d90c729b7d6 Mon Sep 17 00:00:00 2001 From: Logan Lieou Date: Sat, 19 Oct 2019 16:17:29 -0500 Subject: [PATCH] Docs? --- Modules/pandas_tutorial.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/Modules/pandas_tutorial.py b/Modules/pandas_tutorial.py index adb4ef48..3069160a 100644 --- a/Modules/pandas_tutorial.py +++ b/Modules/pandas_tutorial.py @@ -1,11 +1,18 @@ +""" +Introducing pandas using namespace pd, +such that you can call pandas class using pd instead of pandas. +""" + import pandas as pd +# Dict object, with arbitrary data. stats = { 'Month': ['Jan', 'Feb', 'March', 'April'], 'Expenses': [2350, 3400, 2700, 2200], 'Income': [4000, 4000, 4000, 4000] } +# stats is now a pandas data frame object. df = pd.DataFrame(stats) # df = df.set_index('Month') -print(df.Month) \ No newline at end of file +print(df.Month)