Articles tagged with #Python

Type-Safe Pipelines and Compose

Article Header Image

When dealing with multiple transformations that run sequentially, one could leverage the compose function to create pipelines. This article shows different way to implement them in a type-safe way. All the code was written using pure Python 3.11 and MyPy 1.5.1 and PyLance v2023.9.20

ANGEL - An Oppinionated Guide on how to Learn Programming (focusing on Python)

Article Header Image

Courses and pieces of training claiming to deliver rapid results have become increasingly popular these days. Nonetheless, amidst the abundance of online resources, it can be challenging to distinguish valuable ones from the noise. Enter ANGEL, which stands for "ANGEL's Not a Guide to Effortlessly Learning." This guide presents readers with a practical approach to the programming learning experience. While the examples will be specific to Python, the reader can apply the core content to any programming language or framework.

Python Recursion: a Trampoline from the Mutual Head to the Memoized Nested Tail

Article Header Image

Recursion is a key concept of programming. However, it is usually only superficially explored. There are different ways of having recursion, this post will illustrate them using Python examples, call graphs and step-by-step runs. Including cases of head, tail, nested and mutual recursion. For each case, the call graph will be shown.

Add Google Analytics (or any custom HTML) to Streamlit with Github Pages

Article Header Image

Streamlit is one of the most popular libraries for creating web apps using Python, and they also provide a service to freely host and share your apps. One of the issues with this free sharing capability is that one losses control over the app, for instance, it is no longer possible to control how the precise HTML will look like or add custom Open Graph or analytics. This post shows a simple and easy way to add all of this by using Github Pages.

Lessons learnt After Developing Finance Web Tools with Streamlit and Altair (No HTML/CSS/JS)

Article Header Image

There are a lot of resources available online about personal finances, stocks, markets, cryptos, and many more economy-related topics. However the decisions one has to make should be informed in order to be good enough. This post covers the lessons learnt after developing similar tools using Streamlit and Altair. No HTML/CSS/JS were needed. This post will make the reader aware of some pros and cons of this libraries and also show an example app.

Multipage, State-Persistent Apps with Streamlit

Article Header Image

Converting a Python script to a web app has never been easier thanks to libraries such as Streamlit. This library allows to create simple and responsive web apps with minimal effort but there is one potential limitation: No multipage support. In this post, a potential solution to this problem is presented with examples and demos.

Jupyter Publishing Guide: From Embedded to Book

Article Header Image

Jupyter Notebooks are the lingua franca for Data Science. There is hardly any data scientist that has never used this IDE. However, in contrast to its popularity and usefulness, the process of sharing a Jupyter Notebook is not straightforward. This article presents a brief survey of the different publishing solutions available for personal and/or commercial projects.

Embed Interactive Jupyter Notebooks in Static Websites for Free

Article Header Image

After a lot of research on the internet, I found no practical tutorial explaining how to embed Jupyter Notebooks in Static Websites using only free technologies. I found a way to do it using Github Gists, MyBinder and NBInteract along with IPython Widgets and I want to share it so no one has to reinvent the wheel.

Ordinary Differential Equations (ODE) with Python

Article Header Image

When I was at my 3rd year of University I have a complete subject about Ordinary Differential Equations and other similar topics. For that course we used Wolfram Mathematica throughout the year and I asked the teacher whether I can do it with Python, here you can see the results.

Visualizing Math: A Guide to Creating Times Table Animations with Python

Article Header Image

Explore the mesmerizing patterns of times tables with Python! In this blog post, we present an alternative implementation to the famous Mathologer's video where beautiful patterns emerge from times tables. Burkard highlights how stunning patterns arise from these tables and utilizes Wolfram Mathematica to demonstrate these patterns in greater detail. This blog post aims to showcase a similar implementation using Python.

To see every post check the Archive