You must get the Dining Plan for the length of your stay. For example, if you're staying for 7-nights, you must get the DDP for all 7-nights. You cannot get it for only a portion of the stay.
The only way to have the DDP for less nights would be to do a split stay (e.g., one three-night reservation and one 4-night reservation). However, with a split stay there is no guarantee that you'll stay in the same room and you cannot use the DDP credits from one stay during the other stay.
If you want the DDP for just a portion of your stay, you would have to book two separate packages, one with the DDP for the portion that you want the plan and one without for the other nights. You would have to use the DDP credits from the time of check-in on that package until midnight of the day you check-out from that package. The credits couldn't be spread over the time period encompassing both reservations.