1. A method for setting a basal rate profile for an insulin pump, wherein the basal rate profile defines a basal rate delivery for a selected time interval and has a pre-defined number of profile segments each of which define the basal rate delivery for a subset of the selected time interval, the method comprising: providing a curve representing a basal rate as a continuous function of time as an input for an input unit; and generating the basal rate profile from the curve by a the calculation unit by assigning curve values at selected time instances to the pre-defined number of profile segments; wherein the respective subset of the selected time interval varies for each profile segment, there is a threshold for the average deviation over a number of consecutive profile segments, and when the threshold is exceeded, a proposal for corrected amplitude of adjacent profile segments is calculated and presented to a user for approval; and wherein the basal rate delivery is repeated in time and a first profile segment in time is considered adjacent to a last profile segment in time; providing the curve by continuously moving the object across a display area of a touch screen and drawing the curve backward in time or providing the curve as a pre-drawn curve that has been scanned by a scanner; and wherein the user can select either one of the steps of providing the curves.