Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How are pandas dataframes implemented? Can we implement similar dataframes with some customizations?

I need to only some of the functionalities of Pandas dataframe and need to remove others or restrict users from using them. So, I am planning to write my own dataframe class which would only have a subset of methods of Pandas dataframes.

like image 475
Sangram Gaikwad Avatar asked Dec 03 '25 20:12

Sangram Gaikwad


1 Answers

The code for pandas DataFrame object can be found here.

Theoretically you could clone the repository and re-write sections of it. However, it's not a simple object and this may take a decent amount of reading into the code to understand how it works.

For example: pandas describes the dataframe object as a

Two-dimensional size-mutable, potentially heterogeneous tabular data structure with labeled axes (rows and columns). Arithmetic operations align on both row and column labels. Can be thought of as a dict-like container for Series objects.

like image 158
Elijah Moreau-Arnott Avatar answered Dec 05 '25 11:12

Elijah Moreau-Arnott



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!