Refactor timestamp normalization in API class to handle NaN values correctly by dropping them before calculating the maximum timestamp.
Refactor timestamp normalization in API class to handle NaN values correctly by dropping them before calculating the maximum timestamp.