Please enable JS

READING FILES

On reading and extracting data from files in Python, and beginning integral calculus.

READING FILES

NOVEMBER 16, 2016/BARRY COLONNA

I finally finished differential calculus and have begun integral calculus on Khan Academy. I have also completed week 3 of Python Data Structures from the University of Michigan on Coursera, which is super!

Mathematics

img

So far, I haven’t done anything too terribly difficult in my new calculus class. If you’re comfortable with derivatives, then the beginning of integral calculus is no problem. We’re currently studying indefinite integrals, also known as antiderivatives.

An antiderivative is reverting a derivative back to its previous function. For example, taking the formula for an acceleration and calculating the velocity. You always lose constants when you take the derivative of a number, so you’re often missing some data when taking the antiderivative unless you have additional information.

Nonetheless, I’m enjoying it thus far.

img

I still have very few complaints about Khan Academy. New videos are constantly being added to build upon and improve the curriculums that are taught. I have read that math classes provide much more complex examples than the ones in the lectures.

It’s not that I necessarily want to frustrate myself with insanely difficult math problems, but it might be interesting to try some out. I find most of the problems discussed on Khan to be sufficiently challenging while covering the core concepts of the topics that we need to learn. Without knowing the exact mathematical concepts I will need in the future, I can’t say whether or not the lectures are inadequate for my career.

Programming

In programming, we have started working on reading and extracting data from files. Up until this point, we have entered all of our data and strings directly into Python. Now we’re using actual files, which is great because that’s where all the data will come from in my prospective career.

img

I’m feeling more and more comfortable with Python as I use it. The formatting and position of lines of code makes more sense to me now and I can write some incredibly basic programs with relative ease. I still need to review my notes to recall commands and arguments, but I’m getting better.

Our final assignment this week involved reading a text file, extracting numbers from specific lines in the file, and taking the average of all the numbers. When I write it like this, it sounds far easier than it did when I wrote the code!

But I did it and it’s awesome! I’m sure the code is a messy and could be cleaned up a bit with more knowledge, but I’m proud to be able to it.

I should note that I discovered that I get a traceback error after Except because the program doesn't stop running at that point. I didn’t realize my mistake until after taking the screenshot. Please excuse my ignorance (and laziness for not wanting to fix it to take another screenshot). It only creates the problem when I enter the incorrect file name, so it's not mission critical for me to fix it.

That’s about it. We learned a lot of methods to extract data and snippets from text files and some ways to manipulate it. I’m looking forward to continue broadening my knowledge.

Conclusion

Thank you for stopping by. Always reach for your dreams, no matter how difficult they may seem to attain. I believe in you.

Take care. I’ll see you in a week!





JOURNAL

This journal will be about my journey to become a data scientist and better myself through education and fitness.

I hope that my words inspire you to follow your dreams and show you that it's never too late to make a change.

SCHEDULE

Data science posts every Wednesday.

Health posts every other Sunday.

Follow Barry