Python Forum
I need help with Python code to implement this algorithms - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: I need help with Python code to implement this algorithms (/thread-19623.html)



I need help with Python code to implement this algorithms - Saemmanuex - Jul-07-2019

Hello house , I need help with Python code to implement the following algorithm[Image: znKvQDy]

Attached to this is a link to the algorithm[Image: qJt953K]


RE: I need help with Python code to implement this algorithms - DeaD_EyE - Jul-07-2019

Show us your code or do you have no clue how to start?
As first you can make a function to read the PV-data.
I guess you have the data as CSV. There is a built-in Python module called csv to read csv files.
Another function could calculate min and max in one step for one day.
Then you have branching in this diagram, which means there is a if..else block.
Appending data to an array can be done in Python with lists.