[python]pandas.series method

I have two lists, and I use pandas.series method to make it into a table. The table consists of the index column and the data column, the axis is on the top left most of the table which by default is empty, from the axis onwards will be the data column which the name can … Continue reading [python]pandas.series method

[python]Read from delimited files and excel and convert to html with Pandas

Thanks to the creator of Pandas, data extraction from excel and delimited text file is made easy. Below is my modified function that suits to be used to extract data from delimited text files and excel files, then they are converted to html. HTML

[python]Download multiple files from different directories from ftp server

File patterns This is to download multiple files of the same pattern form different directory. In ftp.pyclass.com there are directories organized in year, and within each year there are gunzip files that has this pattern stationId-Year on this example I will be downloading the gunzip files which has a station id 010010-99999, between the year … Continue reading [python]Download multiple files from different directories from ftp server

[python]Download files with FTP client with multithreading

You may wish to enroll the course by Ardit Sulce, I will not reveal the username and password on his ftp.pyclass.com, to be fair to him in order to use his resource for practice and learning data science you got to enroll to his course. The code presented here has 5 parts: security.crypto, for encrypting … Continue reading [python]Download files with FTP client with multithreading

[python]Comparing executed time between with and without threading

To compare between with and without threading, there are three routers from R1 to R3, the task is to save the show version on each router to all.txt. Do the tasks without threading The script runs sequentially on each device, and the total time is 15seconds. Do the tasks with threading The time taken to … Continue reading [python]Comparing executed time between with and without threading

[python]Threading, acquiring and releasing lock to access shared resource.

On previous post about threading, there is no worry of data corruption as each fetch and write is to different destination and write to different file respectively. What if the requirement is to append all data fetched from multiple websites and write them into a single file? There will be race condition which the same … Continue reading [python]Threading, acquiring and releasing lock to access shared resource.