fixes in trend analyzer