Signal Processing Algorithms For Analysis Of Categorical And Numerical Time Series: Application To Sleep Study Data