Sign in

If there’s one thing that makes Python incredibly successful, that would be its readability. Everything else hinges on that: if code is unreadable, it’s hard to maintain. It’s also not beginner-friendly then — a novice getting boggled by unreadable code won’t attempt writing its own one day.

Python was already readable and beginner-friendly before decorators came around. But as the language started getting used for more and more things, Python developers felt the need for more and more features, without cluttering the landscape and making code unreadable.

Decorators area prime-time example of a perfectly implemented feature. It does take a…


“Just be yourself” That’s a really loaded statement isn’t it? How many of us don’t feel comfortable in our own skin? I’m not just talking about looks, you can just not feel like you have a lot to offer. There is a small feeling that nags at you — if you were a little more interesting, if you had something more to say, if you were smarter…

Why do we feel this way at times? A big reason is how much faith we put in others, that they are telling us the truth. There is always that one person that…


Even the most agile project team needs to document the various aspects of what they are trying to accomplish. If you prescribe to more rigid development cycles and continual improvement models, there seems to be a template and detailed process for making tons of documents that don’t seem to bear much fruit. While applicable at times, it is hard to draft a House of Quality structure when your boss gives you 3 days to put a project timeline together.

We can’t let paperwork and needless documentation weigh us down, but having sufficient information to follow, plan and protect ourselves is…


As a content creator you may be posting videos to premier or publish videos live. When doing so, would you like a record of the chat? This would allow you to analyze content and look for positive or negative reactions. If this interests you then pytchat is going to be a big help.

First, the docs provide minimal help, the code they provide either gives you raw json format or requires you to wait eons to see the data. Just try this on any video:

import pytchat
chat = pytchat.create(video_id="uIx8l2xlYVY")
while chat.is_alive():
for c in chat.get().sync_items():
print(f"{c.datetime} [{c.author.name}]- {c.message}")


Machine learning is a form of statistics that has gathered a lot of attention. It is about finding patterns in massive data sets, find a pattern and then apply that to something. There are a lot of different ways to find patterns and they are not necessarily complicated. Today I’m going to provide a great pattern finding technique using the Apriori algorithm in python.

Apriori is an algorithm that looks for frequent item sets. Itemsets are groups of things, they can be numbers, images, emojis, etc. The apriori algorithm looks for a minimum threshold that the set appears in, this…


Today we are going to explore some of the ways you can connect to sql databases with python. A few examples of why you would want to do this are:

  • Querying large data sets without the need to store the data in an intermediate step.
  • To combine data from several disparate databases.
  • To use as a wrapper for an application (sqlite, mariadb, etc)
  • Extracting data from an application with a hosted database.

Let’s dive in and explore the different ways of extracting data and show how to store it.

Oracle

The package that I like to use is cx_Oracle, you can…


Many uses of python involve connections to APIs, databases, or hosted information. Embedding a password in a script is always a bad idea. You can easily forget it is there, and inadvertently share confidential information with others. This is especially important if you regularly are posting content to a public GitHub.

CSV files

Storing important content doesn’t need to be complicated. Simply creating a CSV file that has the information you need in tabular format will certainly do the job. …


Note to the readers: For this tutorial I will be posting and explaining multiple code blocks. I will not be posting code in a “Pythonic” or more advanced format. It is my opinion that longer more laid out blocks are easier to understand. If you disagree, please tell me why! However, if you see code repeated, this is intentional.

Social media has become one of the most prominent aspects of our culture; even a zeitgeist of the early 21st century. It allows anyone to deliver content, true or false, to hundreds or thousands of people. With 96% of the US…

Brian Seko

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store