Calling an attribute defined in a method from another method in data science (python)

I’m learning object oriented programing in a data science context. I want to understand what good practice is in terms of writing methods within a class that relate to one another. When I run my code: I get the following output (only part of the output is shown due to space constrains): I am happy with the output generated by each method. But if I try to call print(data.quality_fun()) without first calling print(data.prepper_fun()), I get an error AttributeError: ‘MyData’ object has no attribute ‘df’. Being new to objected oriented programming, I am wondering if it is considered good practice to

Using Tkinter, Threading and After method

im working on a selenium project using tkinter in python. I want to execute many selenium task at one time(could be up to 100), so I used threading to accomplish this goal, but I came to a problem, due to the fact that I need all individual selenium task to wait a couple seconds between instructions, I used the ‘.after’ method but for some reason my program is still freezing up, I’ve done a lot of research but I cant seem to find the answer yet. Isn’t there a way to use tkinter, threading and some sort of sleeping in

KeyError for multiframe tkinter?

I keep getting a KeyError and I am unsure why. I added a print statement and printed the self.frames dict to ensure that the keys existed, and it appears they do. I’m new to using classes to create multi frame apps so any insight would be helpful. The error: The dict that prints: The code where the error occurs: Answer The keys in your dictionary are the class names, then you’re trying to reference them by the class itself. self.show_frame(StartPage) needs to be self.show_frame(“StartPage”)

How can I get multiple dataframes returned from a class function?

So I have made a class that takes in a ticker symbol, and it returns a dataframe with all the price information for the dates specified. here is the code below: now this works perfectly, but ideally id like to pass in a list of symbols and have it return a seperate df for each symbol. so for example, symbols = [‘aapl’,’googl’,’msft’,’tsla’] and id like it to return 4 seperate dfs, each named aapl_df, msft_df etc. is there any way to do this? ive tried using a for loop like so but im not sure how to get it to

Get value of related object by list of fields in @property

I have two model like this with following fields: I Also I have this list of fields name: And finally I want to I create this @property: But for related objects this isn’t the correct way and I got this error: ‘Profile’ object has no attribute ‘address.postal_code’ How Can I use this list for get value of field of Profile objects and related object values? Notice: I could solve this problem by using eval function, but because of this and this post, I preferred to throw this solution away. Answer Rather than having Profile nose around in its peers’ internals,