What is lambda in Python, and explain time series in machine learning.
Implement this concept by writing analyze_time_series(values, window). The input is a non-empty chronological list of numbers and a positive rolling-window size. Return one record per observation containing the original value, its change from the previous observation, and the average of the current rolling window. The first observation has a null change. Use a lambda for at least one calculation. The rolling average may use fewer than window observations at the beginning of the series.
def analyze_time_series(values, window):