Displaying 7 results from an estimated 7 matches for "npresobs".
2024 Jun 09
2
head.ts, tail.ts loses time
...} else{
if(length(n)<2){
return(window(x, lastn[1], tail(lastn, 1)))
} else {
Cols <- head(1:d[2], n[2])
xn2 <- x[, Cols[1]:tail(Cols, 1)]
return(window(xn2, lastn[1], tail(lastn, 1)))
}
}
}
# examples
head(presidents)
head(presidents, 2)
npresObs <- length(presidents)
head(presidents, 6-npresObs)
try(head(presidents, 1:2)) # 'try-error'
try(head(presidents, 0)) # 'try-error'
# matrix time series
str(pres <- cbind(n=1:length(presidents), presidents))
head(pres, 2)
head(pres, 2-npresObs)
head(pres, 1:2)
head(pres, 2...
2024 Jun 10
1
head.ts, tail.ts loses time
...il(lastn, 1)))
> } else {
> Cols <- head(1:d[2], n[2])
> xn2 <- x[, Cols[1]:tail(Cols, 1)]
> return(window(xn2, lastn[1], tail(lastn, 1)))
> }
> }
> }
>
>
> # examples
> head(presidents)
>
> head(presidents, 2)
>
> npresObs <- length(presidents)
> head(presidents, 6-npresObs)
>
> try(head(presidents, 1:2)) # 'try-error'
>
> try(head(presidents, 0)) # 'try-error'
>
> # matrix time series
> str(pres <- cbind(n=1:length(presidents), presidents))
> head(pres, 2)
>
> h...
2024 Jun 10
2
head.ts, tail.ts loses time
...n[2]) xn2 <- x[,
>>> Cols[1]:tail(Cols, 1)] return(window(xn2, lastn[1],
>>> tail(lastn, 1))) } } }
>>>
>>>
>>> # examples head(presidents)
>>>
>>> head(presidents, 2)
>>>
>>> npresObs <- length(presidents) head(presidents,
>>> 6-npresObs)
>>>
>>> try(head(presidents, 1:2)) # 'try-error'
>>>
>>> try(head(presidents, 0)) # 'try-error'
>>>
>>> # matrix time series str(pr...
2024 Jun 10
1
head.ts, tail.ts loses time
...head(1:d[2], n[2])
>> xn2 <- x[, Cols[1]:tail(Cols, 1)]
>> return(window(xn2, lastn[1], tail(lastn, 1)))
>> }
>> }
>> }
>>
>>
>> # examples
>> head(presidents)
>>
>> head(presidents, 2)
>>
>> npresObs <- length(presidents)
>> head(presidents, 6-npresObs)
>>
>> try(head(presidents, 1:2)) # 'try-error'
>>
>> try(head(presidents, 0)) # 'try-error'
>>
>> # matrix time series
>> str(pres <- cbind(n=1:length(presidents), presidents)...
2024 Jun 11
1
head.ts, tail.ts loses time
...Cols[1]:tail(Cols, 1)] return(window(xn2, lastn[1],
> >>> tail(lastn, 1))) } } }
> >>>
> >>>
> >>> # examples head(presidents)
> >>>
> >>> head(presidents, 2)
> >>>
> >>> npresObs <- length(presidents) head(presidents,
> >>> 6-npresObs)
> >>>
> >>> try(head(presidents, 1:2)) # 'try-error'
> >>>
> >>> try(head(presidents, 0)) # 'try-error'
> >>>
> >>...
2024 Jun 10
1
head.ts, tail.ts loses time
...:tail(Cols, 1)] return(window(xn2, lastn[1],
> >>> tail(lastn, 1))) } } }
> >>>
> >>>
> >>> # examples head(presidents)
> >>>
> >>> head(presidents, 2)
> >>>
> >>> npresObs <- length(presidents) head(presidents,
> >>> 6-npresObs)
> >>>
> >>> try(head(presidents, 1:2)) # 'try-error'
> >>>
> >>> try(head(presidents, 0)) # 'try-error'
> >>>
> &...
2024 Jun 13
0
head.ts, tail.ts loses time
...Cols[1]:tail(Cols, 1)] return(window(xn2, lastn[1],
> >>> tail(lastn, 1))) } } }
> >>>
> >>>
> >>> # examples head(presidents)
> >>>
> >>> head(presidents, 2)
> >>>
> >>> npresObs <- length(presidents) head(presidents,
> >>> 6-npresObs)
> >>>
> >>> try(head(presidents, 1:2)) # 'try-error'
> >>>
> >>> try(head(presidents, 0)) # 'try-error'
> >>>
> >>...