|
17 | 17 | "import matplotlib.pyplot as plt\n",
|
18 | 18 | "\n",
|
19 | 19 | "# Make the graphs a bit prettier, and bigger\n",
|
20 |
| - "pd.set_option('display.mpl_style', 'default') \n", |
| 20 | + "pd.set_option('display.mpl_style', 'default')\n", |
| 21 | + "\n", |
| 22 | + "# This is necessary to show lots of columns in pandas 0.12. \n", |
| 23 | + "# Not necessary in pandas 0.13.\n", |
21 | 24 | "pd.set_option('display.line_width', 5000) \n",
|
22 |
| - "pd.set_option('display.max_columns', 60) \n", |
| 25 | + "pd.set_option('display.max_columns', 60)\n", |
23 | 26 | "\n",
|
24 | 27 | "plt.rcParams['figure.figsize'] = (15, 5)"
|
25 | 28 | ],
|
|
75 | 78 | "cell_type": "markdown",
|
76 | 79 | "metadata": {},
|
77 | 80 | "source": [
|
78 |
| - "When you look at a large dataframe, instead of showing you the contents of the dataframe, it'll show you a *summary*. This includes all the columns, and how many non-null values there are in each column." |
| 81 | + "When you print a large dataframe, it will only show you the first few rows.\n", |
| 82 | + "\n", |
| 83 | + "If you don't see this, don't panic! The default behavior for large dataframes changed between pandas 0.12 and 0.13. Previous to 0.13 it would show you a summary of the dataframe. This includes all the columns, and how many non-null values there are in each column." |
79 | 84 | ]
|
80 | 85 | },
|
81 | 86 | {
|
|
3511 | 3516 | ],
|
3512 | 3517 | "metadata": {},
|
3513 | 3518 | "output_type": "pyout",
|
3514 |
| - "prompt_number": 3, |
| 3519 | + "prompt_number": 4, |
3515 | 3520 | "text": [
|
3516 | 3521 | " Unique Key Created Date Closed Date Agency Agency Name Complaint Type Descriptor Location Type Incident Zip Incident Address Street Name Cross Street 1 Cross Street 2 Intersection Street 1 Intersection Street 2 Address Type City Landmark Facility Type Status Due Date Resolution Action Updated Date Community Board Borough X Coordinate (State Plane) Y Coordinate (State Plane) Park Facility Name Park Borough School Name School Number School Region School Code School Phone Number School Address School City School State School Zip School Not Found School or Citywide Complaint Vehicle Type Taxi Company Borough Taxi Pick Up Location Bridge Highway Name Bridge Highway Direction Road Ramp Bridge Highway Segment Garage Lot Name Ferry Direction Ferry Terminal Name Latitude Longitude Location\n",
|
3517 | 3522 | "0 26589651 10/31/2013 02:08:41 AM NaN NYPD New York City Police Department Noise - Street/Sidewalk Loud Talking Street/Sidewalk 11432 90-03 169 STREET 169 STREET 90 AVENUE 91 AVENUE NaN NaN ADDRESS JAMAICA NaN Precinct Assigned 10/31/2013 10:08:41 AM 10/31/2013 02:35:17 AM 12 QUEENS QUEENS 1042027 197389 Unspecified QUEENS Unspecified Unspecified Unspecified Unspecified Unspecified Unspecified Unspecified Unspecified Unspecified N NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN 40.708275 -73.791604 (40.70827532593202, -73.79160395779721)\n",
|
|
3580 | 3585 | ]
|
3581 | 3586 | }
|
3582 | 3587 | ],
|
3583 |
| - "prompt_number": 3 |
| 3588 | + "prompt_number": 4 |
| 3589 | + }, |
| 3590 | + { |
| 3591 | + "cell_type": "code", |
| 3592 | + "collapsed": false, |
| 3593 | + "input": [], |
| 3594 | + "language": "python", |
| 3595 | + "metadata": {}, |
| 3596 | + "outputs": [] |
3584 | 3597 | },
|
3585 | 3598 | {
|
3586 | 3599 | "cell_type": "markdown",
|
|
0 commit comments