Python: Graphing Accumulative Swing Index (ASI) in Matplotlib 4

preview_player
Показать описание
This video completes the ASI tutorial within Python and concludes with plotting the ASI on matplotlib.

The purpose of this series is to teach mathematics within python. To do this, we will be working with a bunch of the more popular stock indicators used with technical analysis.

With most of the indicators, we will first discuss them, their purpose, then teach how to program them into python, then actually display them on a chart.

Required files:

Рекомендации по теме
Комментарии
Автор

Thanks for the great tutorials, perfect for picking up some new skills, and as good or better than most undergrad lectures. While messing around with this fxn on some other larger data sets, it is possible for the x, y, z vars within the calc_R fxn and/or the x, y vars within the calc_K fxn to be equal, resulting in an artificially truncated dataset since there is no else condition. In either case the resulting R or K values are equal and some >= and/or <= solve the problem each time.

jeffsnell
Автор

@sentdex I've followed your changes but I get the follow error:
main loop list assignment index out of range
Stock to plot: UserWarning: loadtxt: Empty input file: "[]"
warnings.warn('loadtxt: Empty input file: "%s"' % fname)

Can you help?

hemeshpatel
Автор

A big thanks for that great tutorial of yours! I have a few question about the calculation of R. I was running the ASI on a dataset and two things happened.

First one was that the unhandled case in the calculation of R was triggered, meaning that two or more variables were equal. The result was that R was undefined.

Second thing was that R was zero which resulted into a division by zero in the main term.

Both cases could be fixed easily, but I would prefer to do it right, not just somehow. Can you recommend some literature that gives information on that special cases?

digdra
Автор

Thanks so much for this series. I am returning "Currently Pulling gcz16.cmx 2016-01-21 12: 50: 37 main loop time data '1453355426' does not match format '%Y-%m-%d %H:%M:%S'" having put in your fixMe codes. Has Yahoo! changed their date format since you made this series? I am using 2.7 version. Have I made a mistake with the following "eachline = eachLine.replace(fixMe, %H:%M:%S')))" ?

jmahne
Автор

Hello here. I am following alone your adjustment on the old code.But I got error here and there. Could you please post the new code. And also I want to know why need to change it ? Thank you

verykoala
Автор

Can you post the original startingPoint.py for python 3..4.2 ?

arvindsaini
join shbcf.ru