BUG: NaN values not converted to Stata missing values (GH6684) by bashtage · Pull Request #6685 · pandas-dev/pandas (original) (raw)
There are many missing value indicators ranging from . (dot), .a, .b, ..., .z. In principle these allow the reason for the missing value to be encoded (e.g. .a for non-response, .b for negative value, etc), In theory these could be set, and I thought about how to do this once, but I think it probably isn't a feature that would have much use since pandas doesn't really have a good method to handle different types of missing values.
The idea I had at the time would require a passing a second DataFrame with some additional information about the missing data codes to use. Not worth the effort IMO.