global annotations and detrend bugfix