"Input string was not in a correct format" with Gap Filler screener in Strategy Monitor
Author: stukab
Creation Date: 6/11/2020 12:27 AM
profile picture

stukab

#1
1) I read previous posts about how to convert a specific strategy to a screener by changing the loop, I did it on the Gap Filler strategy, however, when i run the strategy after the fact, it displays some errors when it's running, the error is: "error: input string was not in a correct format"
when executing
Compiling the code doesn't return any errors.

2) Does a screener per the suggested code need to be run by the end of Day or can it be ran as a live steam ?
3) I only saw the option to modify/save the strategy, is it possible to save it under a different name instead of overwriting the original ?

Thanks,

Screener Code:


CODE:
Please log in to see this code.


profile picture

Eugene

#2
Welcome to the forums.

When you run a screener in the Strategy Monitor, you're breaking the link between the historical positions and the alerts. IsLastPositionActive will always be false because a Position does not have a chance to be established since by turning the strategy into a screener it's not processing history. Only the entry Alerts will be generated, and Alerts will disappear because the Strategy will not re-create them for the most recent bar.

If your intention is to get only the entry Alerts, simply leave only that part of the code. This should do it for a screener:
CODE:
Please log in to see this code.


QUOTE:
2) Does a screener per the suggested code need to be run by the end of Day or can it be ran as a live steam ?

This particular strategy is end-of-day since gaps are inherently an EOD thing.

P.S. Please do not use external image hosters. They are used to die away regularly, leaving the topics with orphaned image links. Simply attach your images straight before making a post by clicking "Add attachments" and then clicking "Post". It's that simple.

Once post is published, you can edit it to insert the URL between a pair of IMG tags.
profile picture

Eugene

#3
Surprisingly, the error message you're getting isn't caused by the code. It may have to do with a... glitch in Yahoo data. The DataSet you run it on must be Yahoo's, right? A customer from Europe was having it yesterday.
profile picture

Eugene

#4
P.S. Should you have any followup questions or support inquiries, please create a support ticket first:

https://www.wealth-lab.com/Support/Create

We must verify your WLP entitlement. Thanks.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).