Constructor for temporal network points having a constant value
tnpointInst(npoint,timestamptz) → tnpointInst
tnpointSeq(npoint,tstzset) → tnpointDiscSeq
tnpointSeq(npoint,tstzspan,interp='linear') → tnpointContSeq
tnpointSeqSet(npoint,tstzspanset,interp='linear') → tnpointSeqSet
SELECT tnpointInst('Npoint(1, 0.5)', timestamptz '2001-01-01'); -- NPoint(1,0.5)@2001-01-01 SELECT tnpointSeq('Npoint(1, 0.3)', tstzset '{2001-01-01, 2001-01-03, 2001-01-05}'); -- {NPoint(1,0.3)@2001-01-01, NPoint(1,0.3)@2001-01-03, NPoint(1,0.3)@2001-01-05} SELECT tnpointSeq('Npoint(1, 0.5)', tstzspan '[2001-01-01, 2001-01-02]'); -- [NPoint(1,0.5)@2001-01-01, NPoint(1,0.5)@2001-01-02] SELECT tnpointSeqSet('Npoint(1, 0.2)', tstzspanset '{[2001-01-01, 2001-01-03]}', 'step'); -- Interp=Step;{[NPoint(1,0.2)@2001-01-01, NPoint(1,0.2)@2001-01-03]}
Constructor for temporal network points of sequence subtype
tnpointSeq(tnpointInst[],interp={'step','linear'},leftInc bool=true,
rightInc bool=true) →tnpointSeq
SELECT tnpointSeq(ARRAY[tnpoint 'Npoint(1, 0.3)@2001-01-01', 'Npoint(1, 0.5)@2001-01-02', 'Npoint(1, 0.5)@2001-01-03']); -- {NPoint(1,0.3)@2001-01-01, NPoint(1,0.5)@2001-01-02, NPoint(1,0.5)@2001-01-03} SELECT tnpointSeq(ARRAY[tnpoint 'Npoint(1, 0.2)@2001-01-01', 'Npoint(1, 0.4)@2001-01-02', 'Npoint(1, 0.5)@2001-01-03']); -- [NPoint(1,0.2)@2001-01-01, NPoint(1,0.4)@2001-01-02, NPoint(1,0.5)@2001-01-03]
Constructor for temporal network points of sequence set subtype
tnpointSeqset(tnpoint[]) → tnpointSeqSet
tnpointSeqSetGaps(tnpointInst[],maxt=NULL,maxdist=NULL,interp='linear') →
tnpointSeqSet
SELECT tnpointSeqSet(ARRAY[tnpoint '[Npoint(1,0.2)@2001-01-01, Npoint(1,0.4)@2001-01-02, Npoint(1,0.5)@2001-01-03]', '[Npoint(2,0.6)@2001-01-04, Npoint(2,0.6)@2001-01-05]']); /* {[NPoint(1,0.2)@2001-01-01, NPoint(1,0.4)@2001-01-02, NPoint(1,0.5)@2001-01-03], [NPoint(2,0.6)@2001-01-04, NPoint(2,0.6)@2001-01-05]} */ SELECT tnpointSeqSetGaps(ARRAY[tnpoint 'NPoint(1,0.1)@2001-01-01', 'NPoint(1,0.3)@2001-01-03', 'NPoint(1,0.5)@2001-01-05'], '1 day'); -- {[NPoint(1,0.1)@2001-01-01], [NPoint(1,0.3)@2001-01-03], [NPoint(1,0.5)@2001-01-05]}