The disclosure is related to a medical device, a system, a method and a storage medium for prediction of a value related to a medical condition. More particularly the invention relates to prediction of glucose in the blood or prediction of blood pressure. The disclosure enables improved control of glucose in the blood or of blood pressure, since prediction can be made with higher accuracy, even when switching between dynamic modes, corresponding to different states, such as exercising. In one embodiment a medical device (1) is provided, which comprises: a predicting unit (2) for prediction of a value related to a medical condition of a patient at a future point in time, based on at least a measured present value related to the medical condition of the patient; wherein the predicting unit (2) comprises an ensemble predictor (3), for predicting the value at a future point in time, continuously adaptable to different predictor modes based on different states of the patient.