Hi Akshay, I agree - this is something I've wished we had as well. What's been stopping this is that string variables within Ferret are handled in Ferret's Fortran code as arrays of pointers into c structures, which are resolved only as the output line is constructed. So we don't have Fortran character arrays that we could just list along with any numeric variables when applying the given format.
I've sketched out a way to allow for some simple formats, by
parsing the format specifier within Ferret. So, we could let
Ferret do these sorts of formats- where each variable has exactly
one format specifier, and no spacing using the X format spec. is
allowed. list/format=(A, F8.3) dates, numbrs list/format=(A20, F6.2, F6.2, F6.3) dates, lons, lats, numbrs list/format=(A8, A22, F6.3, F6.3, f7.0) ids, dates, lons, lats, numbrs but not other more detailed ones such as list/format=(A7, 3X, 3F6.3) dates, lons, lats, numbrs list/format=(A3, 3X, 3(F6.3,4x,i7) ) [variable list] There's a release coming up just in the next week or so. It's in a final stages of testing, so this won't be in the upcoming release. But for anyone who uses Git-Hub, https://github.com/NOAA-PMEL/Ferret, we can let you know when this is available in the code base. On 3/19/2018 5:16 AM, Akshay Hegde
wrote:
|