teamtomo / cryotypes

Super-simple data structures for cryo-electron tomography data
Other
3 stars 2 forks source link

add `CryoPoseDataFrame` type alias #8

Closed alisterburt closed 2 years ago

alisterburt commented 2 years ago

cc @brisvag

brisvag commented 2 years ago

What is this for exaclt? It just seems more verbose than using pd.DataFrame, and it does not add anything to it as far as I can tell... Not familiar with type aliases though!

alisterburt commented 2 years ago

the idea was that I could indicate in other packages that I'm returning something which conforms to this API, rather than just a dataframe - just adds some semantics, what do you think?

brisvag commented 2 years ago

I guess it doesn't hurt! But it makes me wonder if we could have a type that statically checks dataframe columns... I supposed that wouldn't be static typing anymore tho :P