All pandas classes (TimeSeries, DataFrame, DatetimeIndex, etc.) have pure-Python definitions, so the C API does not exist. You might be better off passing numpy ndarrays from C to your Python code and letting your Python create pandas objects from them.
If necessary, you can use PyObject_CallFunction , etc. to call pandas constructors, but you will need to take care of accessing the names from the module import and check for errors.
source share