Categories Python

7 days 30 days All time Recent Popular
Nano Course On Python For Trading
Module 1

Python makes it very easy to analyze and visualize time series data when you’re a beginner. It's easier when you don't have to install python on your PC (that's why it's a nano course, you'll learn python...

... on the go). You will not be required to install python in your PC but you will be using an amazing python editor, Google Colab Visit

This course is for anyone out there who is confused, frustrated, and just wants this python/finance thing to work!

In Module 1 of this Nano course, we will learn about :

# Using Google Colab
# Importing libraries
# Making a Random Time Series of Black Field Research Stock (fictional)

# Using Google Colab

Intro link is here on YT:

Create a new Notebook at and name it AnythingOfYourChoice.ipynb

You got your notebook ready and now the game is on!
You can add code in these cells and add as many cells as you want

# Importing Libraries

Imports are pretty standard, with a few exceptions.
For the most part, you can import your libraries by running the import.
Type this in the first cell you see. You need not worry about what each of these does, we will understand it later.
Nano Course On Python For Trading
Module 4

In this post, I will attempt to teach you how to write a trading strategy in Equity Segment that runs on your PC and create a Telegram bot that sends you buy/sell signals with Stop Loss.

Prerequisite: If you hadn't gone through the earlier modules, I strongly recommend you go through them all. Module 2:

If you liked my content, you can donate, tip and support me on this link (any amount you prefer)

We are going to implement below strategy:

Rules: There should be three candles -> high of candle 1 > high of candle 2 > high of candle 3 and low of candle 1 < low of candle 2 < low of candle 3, where candle 3 is T-1 day, candle 2 is T-2 day and candle 1 is of T-3 Day, T = today.

If on today(day=T), the stock crosses yesterday high(candle 3), then send a buy signal to your telegram handle with candle 3 low as SL.

Before we get started with code, let's create a telegram bot using BotFather.

Step 1: Search BotFather in the telegram.
Step 2: type /newbot and then give the name to your bot. Refer to the second image as an example