Forum FlexPro – Discuss your topic!

Extract data around extrema

Accueil > Community > FPScript > Extract data around extrema

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #12726
    Anonymous
    Guest

    Hello,

    I’d like to extract data before and after 1000 from extrema.

    I created following formula but it doesn’t work.

    Dim myP = GlobalExtrema(‘Dataset1’,EVENT_POSITIVE,EVENT_INDEX)
    Dim S, F
    S = myP – 1000
    F = myP + 1000
    ‘Dataset1′[S, F]

    Please tell me what’s wrong with it 😥

    Masahiro

    #8390
    Anonymous
    Guest

    Hello,

    I’d like to extract data before and after 1000 from extrema.

    I created following formula but it doesn’t work.

    Dim myP = GlobalExtrema(‘Dataset1’,EVENT_POSITIVE,EVENT_INDEX)
    Dim S, F
    S = myP – 1000
    F = myP + 1000
    ‘Dataset1′[S, F]

    Please tell me what’s wrong with it 😥

    Masahiro

    #9185
    Bernhard KantzBernhard Kantz
    Participant

    The GlobalExtrema-function returns a data series with the indices. Therefore you have to change your FPScript formula as follows:

    Dim myP = GlobalExtrema(‘Dataset1’, EVENT_POSITIVE, EVENT_INDEX)[0]

    support@weisang.com

    #9186
    Anonymous
    Guest

    Thank you.

    Now it works fine!

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.