This work deals with an adaptive and localized time-frequency representation of time-series signals based on rational functions. The proposed rational Discrete Short Time Fourier Transform (DSTFT) is used for extracting discriminative features in EEG data. We take the advantages of bagging ensemble learning and Alternating Decision Tree (ADTree) classifier to detect the seizure segments in presence of seizure-free segments. The effectiveness of different rational systems is compared with the classical Short Time Fourier Transform (STFT). The comparative study demonstrates that Malmquist-Takenaka rational system outperforms STFT while it can provide a tunable time-frequency representation of the EEG signals and less Mean Square Error (MSE) in the inverse transform.