Conversation

my data was too big for google sheets, so i installed and learned python. but now it's too big for my computer, python won't run it. off to buy a new computer i guess?
257
738
Replying to
Unless an expert has spent a lot of time optimizing it, odds are high that there are small tweaks to your code that will cut the memory usage by 2x or more. But if you have less than 32GB of RAM, buy the upgrade anyways.
2
64
500 columns is a bit weird and it might make sense to split this into multiple tables too depending on what the data structure is like but that's something you can figure out SQL is 10x easier to learn than general programming unless you're trying to become a professional
2
58
Show replies
I've managed Excel spreadsheets larger than this before but I have a pretty powerful desktop and even then they were a bit cumbersome. If you're willing to continue learning tools, look into sqlite (a lightweight SQL database) and Django (a python library for databases).
1
2
It sounds like a new computer would work for now. You could also start working with your data in pieces. For example, only load columns needed for each analysis (pandas read_csv method has a "usecols" arg for this). read_csv also has "nrows" for when working a few rows at a time.
16
A new computer is almost certainly unnecessary. Just a guess but, your method of processing the CSV is probably generating a lot of unnecessary “garbage” (memory allocations) for its intermediary steps and this results in the program “crashing” or getting terminated.
1
1