We're starting to come to the end of the quarter. I am hoping to wrap this project up quicker than I would like to. At the same time. I plan to keep on coming back to the same project and making it better and better. Maybe even trying to use a little bit of machine learning to help with the processes.
This progress report might be a little bit more sparse. But we will find out as the day goes along. But first Project 6. Messing around with pandas, seems as though it would serve the project. Plus it would be great knock out more assignments.
Update:
Loving pandas. It's a lot cleaner to use. I still find that it is great to know how to do everything with out importing libraries. The more I think about writing code, the more I think about how do I get someone's computer to automatic download libraries so that I can create something that runs more like software.
Quick notes. Look into the bottom padding on the buttons.
This reminds me of the practice of leaving the file when it is work. Or at least outputting something. It's a lot easier to realize what you are doing when you change something that is working. Rather than trying to figure out what is broken.
The point in which we left off is importing another file. So that I can try and do a vlookup, and determine if the names are already in the database. And at least get those id's in! Looking at the file right now its in a list of of rows... in a list. This is a perfect example of how to use pandas. The only real question is... do I want to clean this up or move the project forward.
The dilemma continues. There are definitely parts of the code where I don't want to switch to pandas. At least right now. It would make some more functions easier to use. But since we are in the development processes. I think it's best to just continue moving forward, and then work on style and cleaning it up a bit later. Which brings us to the next problem. Reusing the pick headers has a problem.It looks like it is selecting each row. But also makes me wonder how do I get a slider on this thing.
Quick and easy fix. But at least now we're ready for trying to compare these two files.
Check first to see what a index(match()) on excel will get me so that I can compare it in python. This is actually a pretty exciting moment. As I do these look ups all the time. Bet they're easier in pandas then a list of lists.
First notes on the file are that we have not de-duplicated it yet. Which is good. Because we need it in that form. Then there area bout 38 matches or so. The columns are over in random columns at the end of the file. Looking into putting them in the first column so I don't loose the index is a rather good idea.
After messing with it a bit, the lists are coming into the look up great. But the problem is lying with my button selection. It's a class, which means I have to check how it's return because, well I need an integer.
I've come to the point where I've realized that I am just posting small steps. And not sowing as much code. I supposed this is a progress report. Not a final write up. Which will be the next point.
The GUI_Header was easy to fix. I just had to call the attribute that I was looking for. Class just start becoming more and more useful.
The lists are comparing to themselves and giving the right information. Only problem is that I am off on the index. This makes me wonder if it's off by just 1? Which it probably is. (looped the short list first, easy fix). The good news is that after this look up on to our sheet, All I have left to do is split the addresses, Split the names, and make it a file. The end is near! Or at least the short end.
At last! The look up is now giving us the IDs. This is a good leaving point at the moment. To be picked up again hopefully a little bit later tonight. Most definitely tomorrow. But if that is the case it'll be another post.
Till then more reading up on pandas.
https://pandas.pydata.org/docs/getting_started/intro_tutorials/01_table_oriented.html
More updates. Because I like using the list in a list method. This is easily convertible over into pandas. There's a fine line between learning and actually writing code. What I've mostly learned, is that there is always and easier way to do it.
Comments
Post a Comment