Problem 1 Use pandas to read Parking.csv and store the entire dataset as a DataFrame. Problem 2 Write a Python function that takes as input a DataFrame containing all of the ticket information and a plate string and returns a tuple containing the following information: (number of open violations, total dollar amount due of all open violations)
Below is 'Parking.csv'
Plate |
State |
License Type |
Issue Date |
Violation Time |
Violation |
Fine Amount |
Penalty Amount |
Interest Amount |
Reduction Amount |
Payment Amount |
Amount Due |
Precinct |
County |
HNU6125 |
NY |
PAS |
8/25/17 |
11:54A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
47 |
BX |
632NDZ |
IN |
PAS |
8/26/17 |
08:16A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
47 |
BX |
C68FVH |
NJ |
PAS |
8/26/17 |
08:20A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
47 |
BX |
NAX52C |
NJ |
PAS |
9/24/04 |
09:32A |
NO PARKING-STREET CLEANING |
$45.00 |
$30.00 |
$0.00 |
$20.00 |
$0.00 |
$55.00 |
43 |
|
0023CBD |
DP |
PAS |
9/24/04 |
12:46A |
NO PARKING-STREET CLEANING |
$65.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$125.00 |
7 |
NY |
059CWD |
DP |
PAS |
10/15/04 |
10:16P |
NO PARKING-STREET CLEANING |
$65.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$125.00 |
19 |
NY |
NAX52C |
NJ |
PAS |
10/18/04 |
09:31A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
43 |
BX |
A00925 |
DP |
PAS |
10/29/04 |
11:02A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$105.00 |
26 |
NY |
CSD 1.00 |
DP |
PAS |
4/7/05 |
11:17A |
NO PARKING-STREET CLEANING |
$65.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$125.00 |
13 |
NY |
002YKD |
DP |
PAS |
9/20/05 |
08:49A |
NO PARKING-STREET CLEANING |
$65.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$125.00 |
13 |
NY |
024DRD |
DP |
PAS |
4/5/05 |
11:40A |
NO PARKING-STREET CLEANING |
$65.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$125.00 |
19 |
NY |
A00925 |
DP |
PAS |
4/11/05 |
11:02A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
26 |
NY |
HJV7703 |
NY |
PAS |
8/26/17 |
08:40A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
47 |
BX |
CXW1078 |
NY |
OMS |
6/1/06 |
09:52A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$0.00 |
$30.00 |
$0.00 |
$75.00 |
112 |
Q |
0006RMD |
DP |
PAS |
6/15/06 |
09:03A |
NO PARKING-STREET CLEANING |
$65.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$125.00 |
19 |
NY |
EVD5399 |
NY |
PAS |
8/26/17 |
08:51A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
47 |
BX |
EHT2555 |
PA |
PAS |
12/14/66 |
11:56A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
67 |
K |
49639JM |
NY |
COM |
9/6/07 |
08:09A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
78 |
K |
DTH1603 |
NY |
PAS |
1/4/10 |
08:11A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$70.57 |
$0.00 |
$0.00 |
$175.57 |
34 |
NY |
TTD 9.00 |
DP |
PAS |
8/31/07 |
10:30A |
NO PARKING-STREET CLEANING |
$65.00 |
$60.00 |
$0.00 |
$0.00 |
$0.00 |
$125.00 |
17 |
|
51972JM |
NY |
COM |
9/20/07 |
11:31A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
83 |
K |
BFF1793 |
MI |
PAS |
6/23/08 |
08:43A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$73.21 |
$0.00 |
$0.00 |
$178.21 |
32 |
NY |
29780AV |
NY |
COM |
3/3/08 |
10:05A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
115 |
Q |
49639JM |
NY |
COM |
3/12/08 |
09:05A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
84 |
K |
BML1477 |
NY |
PAS |
6/6/08 |
12:41P |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$73.74 |
$0.00 |
$0.00 |
$178.74 |
81 |
K |
49639JM |
NY |
COM |
4/1/08 |
08:15A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
78 |
K |
49639JM |
NY |
COM |
4/18/08 |
08:10A |
NO PARKING-STREET CLEANING |
$45.00 |
$10.00 |
$0.00 |
$0.00 |
$0.00 |
$55.00 |
78 |
K |
BAC4439 |
NY |
PAS |
6/26/08 |
07:34A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$73.19 |
$0.00 |
$0.00 |
$178.19 |
66 |
K |
BEE7356 |
NY |
OMS |
6/17/08 |
08:37A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$72.67 |
$0.00 |
$0.00 |
$177.67 |
72 |
K |
BVH1758 |
NY |
OMS |
6/21/08 |
08:33A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$72.47 |
$0.00 |
$0.00 |
$177.47 |
30 |
NY |
DTH1603 |
NY |
PAS |
1/11/10 |
08:16A |
NO PARKING-STREET CLEANING |
$45.00 |
$60.00 |
$70.39 |
$0.00 |
$0.00 |
$175.39 |
34 |
NY |


Trending now
This is a popular solution!
Step by step
Solved in 3 steps with 2 images









