Added option to read time series from input