n class="p">,</span> <span class="n">data_y</span><span class="p">,</span> <span class="n">series_len</span><span class="p">,</span> <span class="n">dataset_pct</span><span class="o">=</span><span class="mf">1.0</span><span class="p">):</span>
    <span class="sd">&quot;&quot;&quot;Slices the train and target dataset time series.</span>

<span class="sd">    Turns each time series into a series of time series, with each series</span>
<span class="sd">    displaced by one step forward to the previous series.