Open jmcrey opened 6 years ago
Thank you for the constructive review! I really appreciate them. This is very informative to me especially the one about being aware of the starting value of a graph, I will certainly take note about that. Of course there are also the solid advices given about coding; using methods that are native to the environments, resetting index on pivot, some ways to organising the codes, which all I will bear in mind. Thanks again for everything!
Overall, this project was incredible. The queries were super clear; the graphs were brilliantly labeled and correctly displayed; the code worked flawlessly and conformed to all of Python's best practices; and the PowerPoint was a pleasure to read. I did want to give a couple things that may help overtime. Fair warning, most of these are preferential recommendations. The first is with
lambda
operator, and I'll just use the following function as an example:df['is_application'] = df.application_date.apply(lambda b: 'Application' if b != None else 'No Application')
Note, this function worked perfectly and completed the task at hand with ease. The only thing that could be changes is the
if
statement. Instead ofif b != None
, we could have usedpandas
native functionnotnull()
to determine if the variableb
was null or not. Here is an example:df['is_application'] = df.application_date.apply(lambda b: 'Application' if pd.notnull(b) else 'No Application')
To be honest, both ways are 100% correct and there isn't much of a difference. Truly, the only difference is that
notnull()
is native topandas
so we can be certain it will always evaluate correctly for a DataFrame. But, honestly, either way is perfectly fine.The next has to do with listing the columns we want to grab in our SQL statements. Again, this is more of a preferential thing, but it might be better to list them one at a time, and have each be on a separate line. Here is an example:
This way, the reader can easily let know which columns they are grabbing without having to read through various variables on a single line. But, again, this is more preference. The way it was initially implemented was perfectly acceptable and just as readable.
In any case, I just want to reiterate that this project was absolutely fantastic. From code to presentation, everything was done magnificently. Excellent job!