I have a Fortran 90 algorithm which uses a derived data type to return data, and I would like to make a python wrapper for this algorithm. I understand that f2py cannot wrap derived data types; is it possible to do so with a C interface for the Fortran algorithm and SWIG? I would have to pass the derived data type into a C struct and then to Python.

Best Regard,
John Salvatier