Skip to content
TheChatArchiveThe Chat Archive
gpt-3.5-turbo-0301· OpenAIAi2 WildChat-4.8M (AI2)

expand this code to 109 data in time series and set the 109 data to data_109. "nDays =…

  1. User

    expand this code to 109 data in time series and set the 109 data to data_109. "nDays = 72; TimeLabel = TimeLabel(2:nDays); Data = Data(2:nDays);

    TimeLabel = datetime(TimeLabel,"InputFormat","yyyyMMdd"); TimeLabel = string(TimeLabel); ts = timeseries(Data,TimeLabel); ts.Name = 'Close'; ts.TimeInfo.Format = 'mmm dd, yyyy';"

  2. Assistant

    nDays = 109; % Change to 109 TimeLabel = TimeLabel(2:nDays); Data = Data(2:nDays);

    TimeLabel = datetime(TimeLabel,"InputFormat","yyyyMMdd"); TimeLabel = string(TimeLabel); data_109 = Data; % Assign the new data to data_109 ts = timeseries(Data,TimeLabel); ts.Name = 'Close'; ts.TimeInfo.Format = 'mmm dd, yyyy';